Re: setPrintJobProperty problem
- Posted by Judith Evans <camping at ccewb.?et> Oct 29, 2007
- 639 views
CChris wrote: > > Judith Evans wrote: > > > > CChris wrote: > > > > > > <big snip/> > > > > > > > CChris, I *had* modified w32Resources.ew as you said. The actual code > > > > is: > > > > > > > > }}} <eucode> > > > > global function getDefaultPrinter() > > > > printerDC = w32Func(xCreateDC,{wsp,pname,0,0}) > > > > setPrinterPointers(1) > > > > return printerDC > > > > end function > > > > </eucode> {{{ > > > > > > > > That was copied direct from C:\Euphoria\Win32Lib\include\w32Resources.ew > > > > I did say that I had put it into Win32Lib - about line 1212 in > > > > w32Resources. > > > > So .... I carry on wondering what is going on! Or what I have done!! > > > > > > > > AndyD > > > > > > Ok, then I'll have to look at this more thoroughly. Tere's a long weekend > > > ahead > > > for Nov. 1st, so I'll probably find some time to set that right. > > > Does the keyboard handler faultlessly work now? > > > > > > CChris > > > > I'm using the 70.2 file you sent and changed Generic.exw in the demos to use > > VOID=getDefaultPrinter() instead of getPrinter(). I also added > > VOID=setPrintJobProperty(JP_Orientation, > > DMORIENT_LANDSCAPE) right after getDefaultPrinter(). I needed to click "OK" > > in one popped up Window but printing shows the text in landscape as desired. > > I'm using a HP 5500 series All-In-One printer. I have no idea what driver it > > uses. > > > > judith > > Good news. Or bad news if the routine orks unreliably, depending to the > printer. > > If I remember correctly, in an earlier email long ago, you mentioned that your > print setup dialog box had some fields that weren't in mine. > I'm afraid that the superfluous dialog box is something some drivers dumbly > display even when obviously not needed. If someone knows better, I'll > appreciate > the input. Otherwise, I'm simply afraid that the extra box may not be avoided > always, depending on the driver. > > I may have an idea, involving a custom template for an invisible dialog box > that would close on open. Not for next version if this is the way to go. > > CChris > btw can you determine which statement causes the dialog box to pop up, tracing > into w32resources.ew? I cannot test this atm. I missed that after the printer is assigned in generic.exw in printdoc routine there is a getPageSetup(). If I comment that then the text is in Portrait just as Andy said he experienced. My tests using Generic.exw opened the getPageSetup dialog where landscape radio button is checked so naturally I got Landscape print. Sorry for the confusion. judith