Hi BlackDevil,
This is how i do it :
Dim crreportobject As
CrystalDecisions.CrystalReports.Engine.ReportObjec t
For Each crreportobject In
crReportDocument.ReportDefinition.ReportObjects
'' formats text object
If TypeOf (crreportobject) Is
CrystalDecisions.CrystalReports.Engine.TextObject Then
Dim crtextobject As
CrystalDecisions.CrystalReports.Engine.TextObject
If Trim(crreportobject.Name) = "Text2" Then
crtextobject = DirectCast(crreportobject,
CrystalDecisions.CrystalReports.Engine.TextObject)
crtextobject.Text = "Hi"
End If
End If
'' formats field object
If TypeOf (crreportobject) Is
CrystalDecisions.CrystalReports.Engine.FieldObject Then
Dim crtextobject As
CrystalDecisions.CrystalReports.Engine.FieldObject
If Trim(crreportobject.Name) = "Field73" Then
crtextobject = DirectCast(crreportobject,
CrystalDecisions.CrystalReports.Engine.FieldObject )
crtextobject.ObjectFormat.HorizontalAlignment =
Alignment.RightAlign
End If
End If
Next
Kind Regards
Jorge
-----Original Message-----
Hello,
Is there a way to format the data when it is passed into
the CrystalReport(CR).. for example.. In the original table, a
number may beleft aligned, how to change it to right alignment?.. in
other words Iwant to change it's Format: Horizontal Alignment
from Left To Right if the
data passed in is an Integer, Currency, or
DateTime.
thanx
.