Hi All;
I have written a macro in ACCPAC 5.3 to call a Crystal Report from ACCPAC. The macro seems to be working and called the report. However, I cannot seem to pass in the record selection parameters. When the report runs, it pops up the Crystal Record selection screen. Is it possible to get the macro to skip this section and take the values from the form. Here is a sample of my code. I have also included the OERPT.INI section that I created.
Set rpt = ReportSelect ("OEBOFL01[OEBOFL01.RPT]", " ", " ")
Dim rptPrintSetup As AccpacCOMAPI.AccpacPrintSetup
Set rptPrintSetup = GetPrintSetup(" ", " ")
rptPrintSetup.DeviceName = "Cheque_Printer"
rptPrintSetup.OutputName = "IP_192.168.190.7"
rptPrintSetup.Orientation = 1
'rptPrintSetup.PaperSize = 1
'rptPrintSetup.PaperSource = 15
rpt.PrinterSetup rptPrintSetup
rpt.SetParam "SFINV", sFromInvoice
rpt.SetParam "STINV", sToInvoice
rpt.NumOfCopies = 1
rpt.Destination = PD_PREVIEW
rpt.PrintDir = ""
rpt.PrintReport
** Object ID = XXXX Order Entry Applet **
[OEBOFL01]
heading="Bill of Lading"
crystal=OEBOFL01
orientation=portrait
paper size=1
optparms=2
2=SFINV STRING
3=STINV STRING
Any ideas?
Stephen
I have written a macro in ACCPAC 5.3 to call a Crystal Report from ACCPAC. The macro seems to be working and called the report. However, I cannot seem to pass in the record selection parameters. When the report runs, it pops up the Crystal Record selection screen. Is it possible to get the macro to skip this section and take the values from the form. Here is a sample of my code. I have also included the OERPT.INI section that I created.
Set rpt = ReportSelect ("OEBOFL01[OEBOFL01.RPT]", " ", " ")
Dim rptPrintSetup As AccpacCOMAPI.AccpacPrintSetup
Set rptPrintSetup = GetPrintSetup(" ", " ")
rptPrintSetup.DeviceName = "Cheque_Printer"
rptPrintSetup.OutputName = "IP_192.168.190.7"
rptPrintSetup.Orientation = 1
'rptPrintSetup.PaperSize = 1
'rptPrintSetup.PaperSource = 15
rpt.PrinterSetup rptPrintSetup
rpt.SetParam "SFINV", sFromInvoice
rpt.SetParam "STINV", sToInvoice
rpt.NumOfCopies = 1
rpt.Destination = PD_PREVIEW
rpt.PrintDir = ""
rpt.PrintReport
** Object ID = XXXX Order Entry Applet **
[OEBOFL01]
heading="Bill of Lading"
crystal=OEBOFL01
orientation=portrait
paper size=1
optparms=2
2=SFINV STRING
3=STINV STRING
Any ideas?
Stephen