Crystal Report Parameters from Delphi: Error 656
Posted on 2003-03-17
New to Delphi and Crystal Report, maintaining a Delphi application interfacing to Crystal Reports.
A couple of report interfaces from Delphi are having parameter problems as follows:
Calls to PEGetNParameterFields and PEGetNthParameterField indicate more parameters than I can find in the .rpt file. In one instance the parameters are repeated such that the names of the first 4 parameters returned from PEGetNthParameterField equal the names of the next 4. PEGetNParameterFields said 8 parameters and I can only find the 4 in the .rpt file. In the other instance I find 8 parameters in the .rpt file and PEGetNParameterFields and PEGetNthParameterField reveal 12 with the first 8 as expected and the last 4 different to any of the 8.
In both cases calls to PESetNthParameterField, one past the number of parameters I see in the .rpt (the logic looping for the number got from PEGetNParameterFields) produce the 656 error which I see in Crystal Help described as "Operation illegal on linked parameter."
I don't understand where PEGetNParameterFields and PEGetNthParameterField are getting their info. from and why it should differ with where PESetNthParameterField is aimed. Any help greatly appreciated.