WITH ThisForm
* Set the report name
.oleCrystal.ReportFileName = "MyReport.RPT"
* Set the destination
.oleCrystal.Destination = 1
* Set the window title
.oleCrystal.WindowTitle = "My Report"
* Cancel the error handler to avoid a bug in Crystal Reports ActiveX control.
* This bug causes and OLE error when the user cancels the report
lcOnError = ON("ERROR")
ON ERROR *
* Activate Crystal Reports
.oleCrystal.Action = 1
* Reset the error handler
ON ERROR &lcOnError.