Connecting Tech Pros Worldwide Forums | Help | Site Map

Passing Parameter in Crystal Report using C#.Net

Newbie
 
Join Date: Sep 2006
Posts: 1
#1: Sep 4 '06
hi

I am working in C#.Net 2005.
I want the whole code for Passing Parameter in Crystal report
Please send it fast
It's very urgent

with regards,
Anushree

Newbie
 
Join Date: Sep 2006
Posts: 14
#2: Sep 15 '06

re: Passing Parameter in Crystal Report using C#.Net


Quote:

Originally Posted by anushree1631

hi

I am working in C#.Net 2005.
I want the whole code for Passing Parameter in Crystal report
Please send it fast
It's very urgent

with regards,
Anushree

Hi

You can write the code as below to pass the parameters.

oReportDocument = new rptSample();
oReportDocument.SetParameterValue("ParameterName", DateValue);

and then open the report rptSample, Open 'Field Explorer' and in that right click on the 'Parameter Fields' and click on the 'New'. It will open the new window 'Create Parameter Field' , in the name field write "ParameterName" and select value type "Date".

That's all.

-Ankit
Reply