Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Crystal 2008 reading TextObject from VB.NET 2005

Hi there,

I have been tasked with rewriting the crystal compiling software for the company i work for.

The previous version was written in VB6 and used an pretty old version of Crystal.

We now use Crystal 2008 and VB.NET 2005.

I have overcome many hurdles and we have implemented the software with success, however there is one final issue that I am struggling with..

When 'compiling' a report for say email dispatching, the previous software would read the value of a ReportObjectKind.TextObject off of the report where its name is 'EmailSibject' and set the subject of the email to that.

The problem im having is because the textobject is dynamic, when I read the value in i get {DATA.DATA_UID} - this is the database field not the value of it that I am after.

The code I am using is as follows:



Dim ReportSectionss As CrystalDecisions.CrystalReports.Engine.Sections = CRReport.ReportDefinition.Sections

For Each CurSection As CrystalDecisions.CrystalReports.Engine.Section In ReportSectionss

For Each RepObj As CrystalDecisions.CrystalReports.Engine.ReportObject In CurSection.ReportObjects

If RepObj.Kind = ReportObjectKind.TextObject Then

Select Case RepObj.Name.ToUpper


EmailSubject = CType(RepObj, CrystalDecisions.CrystalReports.Engine.TextObject).Text

Exit Do

End Select

End If



Exit Do



How would I go about getting the value that is actually displayed of the report?



Edited by: Davec_123 on May 23, 2011 12:59 PM

Former Member
Not what you were looking for? View more on this topic or Ask a question