Helo, I tried to use de global coleciton reportitems in a custom function, but it raise the following error: 'reportitems' is not a member of 'Microsoft.ReportingServices.ReportProcessing.ExprHostObjectModel.IReportObjectModelProxyForCustomCode'
I can use the parameters collection without any problem in the same function. I saw in documentation that parameters, fields and reportitems can't be used in inatialization (onInit()), but I think that this is not the same situation since parameters works fine.
Any idea ?
Tanks
J.Aldrin
ReportItems are not accessible in Custom Code.HTH, Jens Suessmeyer.
http://www.sqlserver2005.de
|||
That's right, by default, custom code directly sees only a subset of collections available in report expressions.
If you call a function Foo defined in custom code from a report expression (like textbox value), you can pass ReportItems collection as an argument:
Function Foo(reportItems as ReportItems)
Return reportItems!textbox1.Value
End Function
<Textbox Name="textbox2">
...
<Value>=Code.Foo(ReportItems)</Value>
...
</Textbox>
HTH, Jens Suessmeyer.
http://www.sqlserver2005.de
No comments:
Post a Comment