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

How can i pass parameters to report from VB

Status
Not open for further replies.

ITeC

Technical User
Apr 9, 2002
20
0
0
GB
Hi,
Iam new to Crystal reports.how can i pass a parameter from vb(at runtime) to report based on which select statement can fetch the data.
ex:select * from emp where empno="parameter"
i have designed report and iam calling that report in vb6.0 using RDC.
would u please send me the code for this or any sugesstions .
Thanks in advance
 
Hi,
I didnot see any formula with your message,please send that
regards
 
REPORTOBJECT.FORMULA(0) = [CLIENTID]

YOU NEED TO HAVE [CLIENTID] AS A FORMULA IN THE CRYSTAL REPORT FIELD

GOOD LUCK
 
If you have create PARAMETERs in the report and Report is the name of your report object in VB, then:

Report.ParameterFields(1).AddCurrentValue <your data>
Report.ParameterFields(2).AddCurrentValue <your data>
...
 
You need to insert blank formulas in the report
and then reference them from within vb as i told you before
i don't have any examples with me right now to show you
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top