henvi...@gmail.com
unread,Apr 4, 2026, 9:15:21 PMApr 4Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Harbour Minigui
Utilizo a classe TPRINT e preciso imprimir uma imagem que consta do RC do sistema, porem, não está sendo impresso.
A imagem é um BMP simples.
A parte da impressão da classe é a seguinte:
METHOD printimagex(nlin,ncol,nlinf,ncolf,ximage) CLASS TPDFPRINT
cimage := ximage
If subs( right(cimage,4) ,1,1)=="."
tem_ex = .t.
Else
tem_ex = .F.
endif
IF FILE(cimage)
DO CASE
CASE UPPER(RIGHT(cimage,4))=".JPG" .OR. UPPER(RIGHT(cimage,5))=".JPEG" .or. !tem_ex
himage = HPDF_LoadJpegImageFromFile(::oPdf, cimage)
CASE UPPER(RIGHT(cimage,4))=".PNG"
himage = HPDF_LoadPngImageFromFile (::oPdf, cimage)
CASE UPPER(RIGHT(cimage,4))=".RAW"
himage = HPDF_LoadRawImageFromFile (::oPdf, cimage)
OTHERWISE
return self
ENDCASE
XFATOR_COL := 2.87
XFATOR := 2.97
nlinf := nlinf - nlin
ncolf := nColf - nCol
nlin:=(PDFheight/XFATOR)-nlin-nlinf
HPDF_Page_DrawImage (::oPage, himage, ncol*XFATOR_COL, nlin*XFATOR, ncolf*XFATOR_COL, nlinf*XFATOR)
eLSE
msginfo("NAO ENCONTRADO ="+cimage)
ENDIF
return self
Não posso abrir mão da classe porque TODOS os relatórios do sistema estão baseados nela
Alguem tem uma idéia ?