回复 1楼yuanbin74的帖子
需要先获取该控件通过 DataFeild 属性设置:
- private void button1_Click(object sender, EventArgs e)
- {
- foreach (var item in reportDesigner.Selection)
- {
- if (item is GrapeCity.ActiveReports.SectionReportModel.TextBox)
- {
- GrapeCity.ActiveReports.SectionReportModel.TextBox tx = item as GrapeCity.ActiveReports.SectionReportModel.TextBox;
- tx.DataField = "订购日期";
- }
- }
- }
复制代码 |