Page 1 of 1
Prchoice Excel Option
Posted: Fri Dec 16, 2016 7:30 am
by omni
Roger,
Found that the excel option has problems if cancelenable is used. I would like to use the cancelenable on print jobs other than excel. Is there a method to do that?
Any help on that is appreciated.
thanks
fred
Omni
Re: Prchoice Excel Option
Posted: Fri Dec 16, 2016 8:15 am
by rdonnay
Your question is ambiguous.
You say that cancelenable doesn't work with Excel but you want to use it without Excel.
I don't know what that means.
Do you have a small test program?
Re: Prchoice Excel Option
Posted: Fri Dec 16, 2016 9:29 am
by omni
In prchoice options:
DCPRINT ON ;
TO oPrinter ;
TITLE "Print Job: " + Alltrim(cTitle) ;
NAME cPrinterName ;
_TEXTONLY saPrintOptions[PRN_TEXTONLY] .AND. saPrintOptions[PRN_MODE] $ {5,6};
_PREVIEW saPrintOptions[PRN_MODE] = 1 ;
; //PSIZE 600, 800 ;
ZOOMFACTOR 1.6 ;
Margin nMargin ;
BUTTONS ABUTTONS FINDBUTTON ;
_ACROBAT saPrintOptions[PRN_MODE] = 2 ;
_EXCEL saPrintOptions[PRN_MODE] = 8 ;
_TOFILE !Empty(cFileName) ;
OUTFILE (cFileName) ;
NOSTOP BUSYMESSAGE "Please Wait............." ;
_HIDE saPrintOptions[PRN_MODE] = 1 ;
ORIENTATION nOrientation ;
SIZE nRows, nCols ;
FONT Alltrim(cFont) ;
_USEDEFAULT saPrintOptions[PRN_MODE] = 4 ;
COPIES nCopies ;
COMBINEEXCELSHEETS ;
//Cancelenable
Roger,
If saPrintOptions[PRN_MODE] = 8 I do not want to Cancelenable
The page counter to cancel does not go away when excel is selected and at some locations just locks up the exe completely. Or maybe add something to turn the print job off, which would probably do the same thing. That is in dc_printeroff. We created our own to add a sleep delay due to some very large print jobs needing time on the server to save prior to opening in excel. That was the only change, but now it will not open the spreadsheet at all. Yours does. That is another issue but no idea why. Do not think it is related to a .ch file that we are aware of.
Thanks
Thanks
Re: Prchoice Excel Option
Posted: Fri Dec 16, 2016 9:45 am
by reganc
Could you use:
.... ;
_ENABLECANCEL saPrintOptions[PRN_MODE] <> 8
It appears that the logical option for this clause has a slightly different name in the dcprint.ch file.
Re: Prchoice Excel Option
Posted: Fri Dec 16, 2016 9:57 am
by omni
Thanks..that is what I was looking for..and it works.
Fred
Omni