I changed line 438 of Printer.prg because PrinterSetup () and GetPrintDC () were not modifying the system printer.
METHOD End() CLASS TPrinter
if ::hDC != 0
if ! ::lMeta
if ::lStarted
EndDoc(::hDC)
endif
else
Aeval(::aMeta,{|val| ferase(val) })
::aMeta := {}
::hDCOut := 0
endif
if ::nOrient != nil
if ::nOrient == DMORIENT_PORTRAIT
::SetPortrait()
else
::SetLandscape()
endif
endif
// PrinterEnd() -> 01/03/2018 (OASYS) Tirei essa linha para que ele mantenha a impressora selecionada no GetPrintDC() sem precisar mudar a impressora Default do Windows.
DeleteDC( ::hDC )
::hDC := 0
endif
if ::oFont != nil
::oFont:End()
endif
oPrinter := nil
return nilOscar Ribeiro
OASyS Informática
Fwh18.02 + xHarbour 1.2.3 + Bcc72
OASyS Informática
Fwh18.02 + xHarbour 1.2.3 + Bcc72