I have a VFP form that runs Crystal Reports. I successfully pass date parameters to the Crystal Reports, except when I have a Crystal Report that has two subreports within it. I can run the Crystal Report in stand-alone mode without using VFP and I am prompted for the start and end dates for subreport number 1 and subreport number 2, but when I try to pass those same dates via parameters, only the first start and end date get passed. Then Crystal Report fires up and prompt me for the second start and end date.
Here is my code.
THISFORM.olecontrol1.ParameterFields(0) = "s_date;Date("+s_yr+","+s_mo+","+s_day+");TRUE"
THISFORM.olecontrol1.ParameterFields(1) = "e_date;Date("+e_yr+","+e_mo+","+e_day+");TRUE"
THISFORM.olecontrol1.ParameterFields(2) = "s_date;Date("+s_yr+","+s_mo+","+s_day+");TRUE"
THISFORM.olecontrol1.ParameterFields(3) = "e_date;Date("+e_yr+","+e_mo+","+e_day+");TRUE"
THISFORM.olecontrol1.ReportFileName = "\reports\shockingnumbers.rpt"
testout = THISFORM.olecontrol1.PrintReport
What am I missing or doing wrong? Thanks for the help.
Steve Kramer
Kramer & Kramer Design
"Home of Go Cartoons"
Web Site:
www.stephenkramer.comWould you believe Far Side Lite?
More than 270 original cartoons.