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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Selection Criteria for Crystal Reports

Status
Not open for further replies.

geedubcpa

Programmer
Oct 5, 2005
19
US
I have a crystal report question in regards to passing a date from a textbox on my form to the crystal report.

I want the report to select the date in my textbox1 as the selected date on the report.

Can anyone point me in the proper direction.

 
Ok here is a quick answer if you need more help please ask and i'll try and find the code i used.

First create a prameter in the report, give it a name and the use the report selection critera to select the records with that date.

The following code is an example and won't work but should give you an idea of how you go about poplating that param with the date in your textbox.

Dim report as new crystalreport

report.reportsource = filename
report.parameters("nameofparm").value = textbox1.text

frm.crystalreportviewer1.report = report

frm.crystalreportviewer1.refresh

Hope this helps.

Hugh





 
Also, for future reference, there are a few Tex-Tips fora dedicated to Crystal Reports. The one that deals with using CR with other programs is forum768 - Business Objects: Crystal Reports 3 Integrate Forum

I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top