Link to home
Start Free TrialLog in
Avatar of Ahmadal_najjar2003
Ahmadal_najjar2003Flag for Kuwait

asked on

Change text on crystal report

Salam

I have a crystal report that have text fields , which I want to change thier text inside the code.

Dim MyReport As New CashierClosedByCashierClosedIDRPT
MyReport.Section2.ReportObjects.Item("ClosedDate").text= SomeThing

but error come up like this
Error      7      'text' is not a member of 'CrystalDecisions.CrystalReports.Engine.ReportObject'.      


Avatar of Mike McCracken
Mike McCracken

Is the field a text or  database field?

I think you can just change it


MyReport.Section2.ReportObjects.Item("ClosedDate")= "SomeThing "

What version of Crystal?
mlmcc
Avatar of Ahmadal_najjar2003

ASKER

FIrst it is a text not a database field

Second I tried your code but give error :

Error      7      Property 'Item' is 'ReadOnly'.      
ASKER CERTIFIED SOLUTION
Avatar of Brad Brett
Brad Brett
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Another option is to pass parameters to the report and use as text.
That's  really bery nice function

Thank you vey much