Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.clipper.visual-objects > #4993
| From | Alain Carpentier <alain.dot.carpentier@brutele.dot.be> |
|---|---|
| Newsgroups | comp.lang.clipper.visual-objects |
| Subject | Re: Problem with print. Somebody help!!!!!!!!!! |
| Date | 2013-03-31 12:32 +0200 |
| Organization | Aioe.org NNTP Server |
| Message-ID | <kj93d0$5dd$1@speranza.aioe.org> (permalink) |
| References | <66191c25-3a1c-459d-9743-43086d0c63cc@googlegroups.com> |
Hello,
I had the same problem.
Maibe a bug in the SDK ?
Try this, it worked for me :
CLASS _PrintingDevice INHERIT PrintingDevice
METHOD UpdateDevMode() CLASS _PrintingDevice
LOCAL iRes as int
IF (pDevMode == null_ptr)
RETURN FALSE
ENDIF
//iRes := PCALL(gpfnDocumentProperties, NULL_PTR, hPrinter,
String2Psz(cDevice), NULL_PTR, pDevMode, DM_MODIFY)
//iRes = return allways -1
// see Remarks n° 5 in DocumentProperties() of Windows SDK
iRes := DocumentProperties(null_ptr, hPrinter, String2Psz(cDevice),
pDevMode, pDevMode, _or(DM_IN_BUFFER, DM_OUT_BUFFER))
RETURN (iRes >= 0)
Alain
Le 30/03/2013 18:09, BGeorge21@in.gr a écrit :
> I have a problem with my prints.
> Code:
> METHOD PrintMyJob() CLASS WPrinting //PushButton
> //Print
> LOCAL oPrinter AS PrintingDevice
> LOCAL structDevMode AS _WINDEVMODE
>
> oPrinter:=PrintingDevice{}
> structDevMode.dmCopies:=oDCSingleLineEdit1:Value
> IF oCCRadioButton1:Pressed
> structDevMode.dmOrientation:=1
> ELSEIF oCCRadioButton2:Pressed
> structDevMode.dmOrientation:=2
> ENDIF
> DO CASE
> CASE oDCComboBox2:Value=="A3"
> structDevMode.dmPaperSize:=8
> CASE oDCComboBox2:Value=="A4"
> structDevMode.dmPaperSize:=9
> CASE oDCComboBox2:Value=="A5"
> structDevMode.dmPaperSize:=11
> CASE oDCComboBox2:Value=="B4"
> structDevMode.dmPaperSize:=12
> CASE oDCComboBox2:Value=="B5"
> structDevMode.dmPaperSize:=13
> ENDCASE
> iSucess:=oPrinter:UpdateDevMode()
> IF iSucess
> Minima("Παρουσιάστηκε πρόβλημα με την εκτύπωση")//Message for problem with print
> ELSE
> oDCRichEdit1:Print(oPrinter)
> ENDIF
> oPrinter: Destroy()
> SELF:EndDialog()
>
> Sorry for my poor english!!!!
> The problem is "oPrinter:UpdateDevMode()" not sucess everytime and always print in Α4,vertical printing and copies 1.
> I checked that the arguments of structure "structDevMode" pass normally to oPrinter.
> Also i checked in 3 different printers and the problem is the same.
> Do you know someebody what am i do wrong?
>
> Thanks and sory again for my poor english.
>
Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Problem with print. Somebody help!!!!!!!!!! BGeorge21@in.gr - 2013-03-30 10:09 -0700
Re: Problem with print. Somebody help!!!!!!!!!! Alain Carpentier <alain.dot.carpentier@brutele.dot.be> - 2013-03-31 12:32 +0200
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-02 01:04 -0700
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-02 01:08 -0700
Re: Problem with print. Somebody help!!!!!!!!!! Alain Carpentier <alain.dot.carpentier@brutele.dot.be> - 2013-04-02 16:36 +0200
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-03 02:23 -0700
Re: Problem with print. Somebody help!!!!!!!!!! Alain Carpentier <alain.dot.carpentier@brutele.dot.be> - 2013-04-03 14:01 +0200
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-03 08:14 -0700
Re: Problem with print. Somebody help!!!!!!!!!! Alain Carpentier <alain.dot.carpentier@brutele.dot.be> - 2013-04-03 22:59 +0200
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-04 12:23 -0700
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-03-31 09:19 -0700
Re: Problem with print. Somebody help!!!!!!!!!! Gustavo Biasone <rosario.soft@gmail.com> - 2013-04-01 08:10 -0700
Re: Problem with print. Somebody help!!!!!!!!!! BGeorge <bgeorge21@in.gr> - 2013-04-01 08:18 -0700
csiph-web