Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB using RDC add multiple value to param... 1

Status
Not open for further replies.

Jacob438

Programmer
Jul 27, 2001
69
US
I am using VB 6 and the RDC method to implement an automated Crystal Reports generator. I see that there is a SetNthDefaultValue property that will set the nth default value. This is kind of good, however, is there a SetNthCurrentValue? Or anything like that? I am having a hard time with this. I just want to be able to pass in two values for one parameter automatically, why is this so hard? Setting the default does me no good if I can't set the "CurrentValue" to that without user intervention.

TIA

Jacob438
 
Jacob,

You need to use the "AddCurrentValue" method:

Report.ParameterFields(1).ClearCurrentValueAndRange
and then multiple calls to:
Report.ParameterFields(ai_counter).AddCurrentValue(your_value)

Cheers,
- Ido

CUT, Visual CUT, and DataLink Viewer:
view, e-mail, export, burst, distribute, and schedule Crystal Reports.
 
That should be:

Report.ParameterFields(1).ClearCurrentValueAndRange
and then multiple calls to:
Report.ParameterFields(1).AddCurrentValue(your_value)

- Ido CUT, Visual CUT, and DataLink Viewer:
view, e-mail, export, burst, distribute, and schedule Crystal Reports.
 
oh cool, thanks, that did the trick allright, I'm surprised I didn't try that, it's just that I couldn't find any documentation on that, thanks a lot!

Jacob438
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top