 | | From: | Tom Waggoner | | Subject: | RDC Print command - Not Working | | Date: | Wed, 15 Dec 2004 09:00:54 -0600 |
|
|
 | Tom Waggoner
Updated to V2.5 and I am using CR V9.0. I use the following code to print Order Confirmations from a list file (dbf). I know it worked with the older version. Since I upgraded it does not work.
oRDC=new OleAutoClient("CrystalRuntime.Application.9") oReport1=oRDC.OpenReport("K:\AMS\Crystal Reports\Ord_Confirm.rpt") oReport1.Printout(true)
When I run the module I get an OLE Dispatch Exception: Not Supported and it is pointing to the last line of code.
Anyone recognize the problem or have another approach? I would like to use ChoosePrinter() which worked very nicely under VdBase 5.7.
|
|
 | | From: | news.alldbase.com | | Subject: | Re: RDC Print command - Not Working | | Date: | Wed, 15 Dec 2004 13:40:04 -0500 |
|
|
 | Try adding number of copies as a second parameter. oReport1.Printout(true,1)
-- Rich... www.autotraker.com AutoTraker Inc.
"Tom Waggoner" wrote in message news:TgM2DYr4EHA.1644@news-server... > Tom Waggoner > > Updated to V2.5 and I am using CR V9.0. I use the following code to print > Order Confirmations from a list file (dbf). I know it worked with the > older > version. Since I upgraded it does not work. > > oRDC=new OleAutoClient("CrystalRuntime.Application.9") > oReport1=oRDC.OpenReport("K:\AMS\Crystal Reports\Ord_Confirm.rpt") > oReport1.Printout(true) > > When I run the module I get an OLE Dispatch Exception: Not Supported and > it > is pointing to the last line of code. > > Anyone recognize the problem or have another approach? I would like to > use > ChoosePrinter() which worked very nicely under VdBase 5.7. > > >
|
|
 | | From: | *Lysander* | | Subject: | Re: RDC Print command - Not Working | | Date: | Wed, 15 Dec 2004 19:13:39 +0100 |
|
|
 | Tom Waggoner schrieb:
> Anyone recognize the problem or have another approach? I would like to use > ChoosePrinter() which worked very nicely under VdBase 5.7.
1.) Check, if with installing 2.5 something on the BDE got changed. You can make a basic test by opening the report from within Crystal Reports and then trying to print it.
2.) There is a method called "printersetup". You can use it for example like this:
OReport.PrinterSetup(Form.hWnd)
works like the good old chooseprinter() for me :)
ciao, André
|
|