I'm trying to access the Crystal Reports COM Object and cannot set the 'ParameterFields' property. This property is actually an array in the COM object. The syntax in VB is simple:
CrystalReport.ParameterFields(0) = "StartHour;12;TRUE"
This won't work in CF: I cannot use a "function on the left side of an assignment". I also tried using CF array syntax [], and setting the property = to a CF array ( <CFSET CR.ParameterFields = myArray> )
I don't think this is specifically a Crystal problem but rather one with property arrays in general.
Here's my code. The error line is commented out.
CrystalReport.ParameterFields(0) = "StartHour;12;TRUE"
This won't work in CF: I cannot use a "function on the left side of an assignment". I also tried using CF array syntax [], and setting the property = to a CF array ( <CFSET CR.ParameterFields = myArray> )
I don't think this is specifically a Crystal problem but rather one with property arrays in general.
Here's my code. The error line is commented out.
Code:
<CFOBJECT TYPE="COM" ACTION="Create"
CLASS="Crystal.CrystalReport"
NAME="CrystalReport">
<CFSET CrystalReport.ReportFileName = "filename.rpt">
<CFSET CrystalReport.Connect = "DSN=DSN_NAME">
<CFSET CrystalReport.Destination = 0>
<!---
I can't get the parameters working correctly from CF.
<CFSET CrystalReport.ParameterFields(0) = "StartHour;12;TRUE">
--->
<!--- Display the report --->
<CFSET CrystalReport.Action = 1>