将数据绑定到IFieldObject

将数据绑定到IFieldObject

本文介绍了将数据绑定到IFieldObject的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我有一个子报告,可以在主报告上显示6次。每次出现的数据都会略有不同。子报表使用未绑定的字符串和数字格式化。 我的第一个偏好是somethig like:'设置子报表的数据源 rpt.Subreports(0)。 SetDataSource(dTarget) rpt.Subreports(1).SetDataSource(dTarget) rpt.Subreports(2).SetDataSource( dTarget) rpt.Subreports(3).SetDataSource(dTarget)等............ '将未绑定字段设置为数据字段(这是我在对象中找不到的假设属性) rpt.Subreports(0).Fields(" UnboundString1")。DataField = dTarget .Salesman 等其他子报告的其他字段 如果我不能得到它,那么如何将未绑定的字段绑定到数据字段?我认为绑定我拥有的字段比将数据字段拖放到每个子报表并且必须格式化每个子报表更容易。 感谢您的帮助。 Rich GRG 解决方案 Hi Rich G I have a subreport that will apear on a main report 6 times.  The data in each occurance will be slightly different.  The subreport was formatted using unbound strings and numbers.My first preference would be somethig like:'Set the datasource for the subreportsrpt.Subreports(0).SetDataSource(dTarget)rpt.Subreports(1).SetDataSource(dTarget)rpt.Subreports(2).SetDataSource(dTarget)rpt.Subreports(3).SetDataSource(dTarget)etc...........'Set the unboundfield to a data field (this is a hypothetical property which I cannot find in the object)rpt.Subreports(0).Fields("UnboundString1").DataField=dTarget.Salesmanetc for the rest of the fields in the rest of the subreportsIf I cannot get that, then how do I bind an unbound field to a data field?  I think it would be easier to bind the fields I have rather than draging a data field onto each subreport and having to format each one.Thanks for the help.RichGRG 解决方案 Hi Rich G 这篇关于将数据绑定到IFieldObject的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-20 22:34