FastReport 自定义数据集
1、可以自定义一个新的数据源
参考:
internal class VirtualDataSource : DataSourceBase
{
private int FVirtualRowsCount;
public int VirtualRowsCount
{
get { return FVirtualRowsCount; }
set { FVirtualRowsCount = value; }
}
#region Protected Methods
/// <inheritdoc/>
protected override object GetValue(Column column)
{
return null;
}
#endregion
#region Public Methods
public override void InitSchema()
{
// do nothing
}
public override void LoadData(ArrayList rows)
{
rows.Clear();
for (int i = 0; i < FVirtualRowsCount; i++)
{
rows.Add(0);
}
}
#endregion
}
2、可以继承 TableDataSource 修改 LoadData 方法。
3、想要可视化设计,必须继承 DataConnectionBase 实现相应的方法。
public override string[] GetTableNames()
public override string QuoteIdentifier(string value, DbConnection connection)
public override Type GetConnectionType()
public override DbDataAdapter GetAdapter(string selectCommand, DbConnection connection,
CommandParameterCollection parameters)
/// <inheritdoc/>
public override ConnectionEditorBase GetEditor()
{
return new MsSqlConnectionEditor();
}
/// <inheritdoc/>
public override Type GetParameterType()
{
return typeof(SqlDbType);
}
/// <inheritdoc/>
public override int GetDefaultParameterType()
{
return (int)SqlDbType.VarChar;
}
/// <inheritdoc/>
public override string GetConnectionId()
{
SqlConnectionStringBuilder builder = new SqlConnectionStringBuilder(ConnectionString);
string info = builder.InitialCatalog;
if (String.IsNullOrEmpty(info))
info = builder.AttachDBFilename;
return "MS SQL: " + info;
}
}
FastReport 自定义数据集的更多相关文章
- torch_13_自定义数据集实战
1.将图片的路径和标签写入csv文件并实现读取 # 创建一个文件,包含image,存放方式:label pokemeon\\mew\\0001.jpg,0 def load_csv(self,file ...
- Tensorflow2 自定义数据集图片完成图片分类任务
对于自定义数据集的图片任务,通用流程一般分为以下几个步骤: Load data Train-Val-Test Build model Transfer Learning 其中大部分精力会花在数据的准备 ...
- pytorch加载语音类自定义数据集
pytorch对一下常用的公开数据集有很方便的API接口,但是当我们需要使用自己的数据集训练神经网络时,就需要自定义数据集,在pytorch中,提供了一些类,方便我们定义自己的数据集合 torch.u ...
- MMDetection 快速开始,训练自定义数据集
本文将快速引导使用 MMDetection ,记录了实践中需注意的一些问题. 环境准备 基础环境 Nvidia 显卡的主机 Ubuntu 18.04 系统安装,可见 制作 USB 启动盘,及系统安装 ...
- Scaled-YOLOv4 快速开始,训练自定义数据集
代码: https://github.com/ikuokuo/start-scaled-yolov4 Scaled-YOLOv4 代码: https://github.com/WongKinYiu/S ...
- PyTorch 自定义数据集
准备数据 准备 COCO128 数据集,其是 COCO train2017 前 128 个数据.按 YOLOv5 组织的目录: $ tree ~/datasets/coco128 -L 2 /home ...
- FastReport自定义数据源及ListView控件的使用
##1.想批量生成一堆物资信息卡,效果如下图所示,fastreport可以一下全部生成,并且发现不用单独写东西, ##2.发现FastReport官方给出的Demo.exe很友好,基本可以满足要求,想 ...
- [炼丹术]YOLOv5训练自定义数据集
YOLOv5训练自定义数据 一.开始之前的准备工作 克隆 repo 并在Python>=3.6.0环境中安装requirements.txt,包括PyTorch>=1.7.模型和数据集会从 ...
- yolov5训练自定义数据集
yolov5训练自定义数据 step1:参考文献及代码 博客 https://blog.csdn.net/weixin_41868104/article/details/107339535 githu ...
随机推荐
- Java selenium web页面的滚动条操作
摘录自:http://blog.csdn.net/iceryan/article/details/8162703 //移动到元素element对象的"顶端"与当前窗口的" ...
- java:IO流学习小结
可以看以下内容学习一下: http://blog.csdn.net/zzp_403184692/article/details/8057693
- UI进阶 跳转系统设置相关界面的方法
跳转系统设置界面,例如提示用户打开定位.蓝牙或者WIFI,提醒用户打开推送或者位置权限等 在iOS6之后,第三方应用需要跳转系统设置界面,需要在URL type中添加一个prefs值,如下图: 跳转系 ...
- tableLayoutPanel的使用
https://msdn.microsoft.com/en-us/library/ms171687(v=vs.110).aspx Controls in a TableLayoutPanel cont ...
- ElasticSearch与Spring Boot集成问题
1.None of the configured nodes are available 或者 org.elasticsearch.transport.RemoteTransportException ...
- Sprint(第九天11.22)
- 团队作业week14
0 如果你的团队来了一个新队员,有一台全新的机器,你们是否有一个文档,只要设置了相应的权限,她就可以根据文档,从头开始搭建环境, 并成功地把最新.最稳定版本的软件编译出来,并运行必要的单元测试?(在这 ...
- Java开发基础
天数 课程 01 Java基础回顾 集合 泛型 IO流 多线程 Junit Properties HTML JavaScript JavaScript BOM编程 XML基础 ...
- react 学习笔记
1.Router 1.1 Histories React Router 是建立在 history 之上的.一个 history 知道如何去监听浏览器地址栏的变化, 并解析这个 URL 转化为 loca ...
- 利用Spring中同名Bean相互覆盖的特性,定制平台的类内容。
欢迎和大家交流技术相关问题: 邮箱: jiangxinnju@163.com 博客园地址: http://www.cnblogs.com/jiangxinnju GitHub地址: https://g ...