Zoom em HBPrint
Enviado: 01 Jul 2008 12:12
boa tarde,
como faço pra dar definir um zoom nos meus relatorios quando coloco o preview na tela
pois a letra esta muito pequena.
meu codigo:
Function BTN_Imprimir_FOLHA()
Local nLinha := 0
Local nPagina := 1
Wcodfolha := _codfolha
Wapres := substr(_apres,3,4)+substr(_apres,1,2)
DbSelectArea('RepMov')
OrdSetFocus('RepMov1')
RepMov->(DbGoTop())
Seek Str( Wcodfolha, 2 )+Wapres
If !found()
MsgStop("Não existe dados pra imprimir !!!")
Endif
PRIVATE aPrinters, aports
INIT PRINTSYS
GET PRINTERS TO aprinters
GET PORTS TO aports
RELEASE PRINTSYS
INIT PRINTSYS
SELECT BY DIALOG PREVIEW
// chama caixa de dialogo do windows
// com PREVIEW
If HBPRNERROR>0
return
Endif
* Retrato Set Page orientation DMORIENT_PORTRAIT papersize DMPAPER_A4 font "f0"
*DMORIENT_LANDSCAPE
Set Page orientation DMORIENT_LANDSCAPE papersize DMPAPER_A4 font "f0"
define font "f0" name "courier new" size 12 bold
define font "f1" name "courier new" size 10 bold
define font "f2" name "times new roman" size 30 width 30 bold italic underline strikeout
define font "f3" name "times new roman" size 30 bold
define font "f4" name "times new roman" size 12 bold
define pen "p0" style PS_SOLID width 1 color 0x000000
define pen "p1" style PS_SOLID width 10 color 0xFF0000
define pen "p2" style PS_NULL
define brush "b0" style BS_SOLID color 0xCCFFAA
define brush "b1" style BS_HATCHED color hbprn:dxcolors("YELLOW") hatch HS_DIAGCROSS
define brush "b2" style BS_NULL
Select font "f0"
Select pen "p0"
START DOC NAME "FOLHA"
SELECT PEN "P1"
SELECT BRUSH "B0"
START PAGE
Cab_RESUMO(nPagina)
Rod_RESUMO()
END PAGE
END DOC
RELEASE PRINTSYS
RETURN
*---------------------------
Function Cab_Resumo(pPagina)
@ 01, 05 Say 'TESTE' FONT 'f0' to print
@ 02, 05 Say 'TESTE' FONT 'f0' to PRINT
Return(Nil)
*---------------------------
Function Rod_Resumo()
@ 66, 05, 66, 150 LINE PEN 'P1'
@ 67, 05 Say 'Impresso em '+DtoC(Date())+' as '+Time() TO PRINT
Return(Nil)
*---------------------------------------------------------------------------
como faço pra dar definir um zoom nos meus relatorios quando coloco o preview na tela
pois a letra esta muito pequena.
meu codigo:
Function BTN_Imprimir_FOLHA()
Local nLinha := 0
Local nPagina := 1
Wcodfolha := _codfolha
Wapres := substr(_apres,3,4)+substr(_apres,1,2)
DbSelectArea('RepMov')
OrdSetFocus('RepMov1')
RepMov->(DbGoTop())
Seek Str( Wcodfolha, 2 )+Wapres
If !found()
MsgStop("Não existe dados pra imprimir !!!")
Endif
PRIVATE aPrinters, aports
INIT PRINTSYS
GET PRINTERS TO aprinters
GET PORTS TO aports
RELEASE PRINTSYS
INIT PRINTSYS
SELECT BY DIALOG PREVIEW
// chama caixa de dialogo do windows
// com PREVIEW
If HBPRNERROR>0
return
Endif
* Retrato Set Page orientation DMORIENT_PORTRAIT papersize DMPAPER_A4 font "f0"
*DMORIENT_LANDSCAPE
Set Page orientation DMORIENT_LANDSCAPE papersize DMPAPER_A4 font "f0"
define font "f0" name "courier new" size 12 bold
define font "f1" name "courier new" size 10 bold
define font "f2" name "times new roman" size 30 width 30 bold italic underline strikeout
define font "f3" name "times new roman" size 30 bold
define font "f4" name "times new roman" size 12 bold
define pen "p0" style PS_SOLID width 1 color 0x000000
define pen "p1" style PS_SOLID width 10 color 0xFF0000
define pen "p2" style PS_NULL
define brush "b0" style BS_SOLID color 0xCCFFAA
define brush "b1" style BS_HATCHED color hbprn:dxcolors("YELLOW") hatch HS_DIAGCROSS
define brush "b2" style BS_NULL
Select font "f0"
Select pen "p0"
START DOC NAME "FOLHA"
SELECT PEN "P1"
SELECT BRUSH "B0"
START PAGE
Cab_RESUMO(nPagina)
Rod_RESUMO()
END PAGE
END DOC
RELEASE PRINTSYS
RETURN
*---------------------------
Function Cab_Resumo(pPagina)
@ 01, 05 Say 'TESTE' FONT 'f0' to print
@ 02, 05 Say 'TESTE' FONT 'f0' to PRINT
Return(Nil)
*---------------------------
Function Rod_Resumo()
@ 66, 05, 66, 150 LINE PEN 'P1'
@ 67, 05 Say 'Impresso em '+DtoC(Date())+' as '+Time() TO PRINT
Return(Nil)
*---------------------------------------------------------------------------