The following example demonstrates how to set parameters using the Crystl32.ocx from Crystal Reports version 7 with Maintenance Release 1, which is the same for version 8.
All parameters including Stored Procedure and Crystal Parameters are set with the ParameterFields property. The exception is date-time Stored Procedures that are set with the StoredProcParam property.
For Example:
In the Report Designer a report has the following three parameters that appear in the "Insert Parameter" dialog box like this:
- The index for the date-time Stored Procedure parameter matches the position in the list from the "Insert Parameter" dialog box beginning at zero for the first item.
- All parameters set with ParameterFields property can be in any order. The indexing is for VB to set aside memory for the parameter. In Crystal Reports the name of the parameter will be used to pass the proper value to the Crystal Report Parameter or Stored Procedure.
e.
The following code passes in null values to a stored procedure that prompts for two parameters.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.