xsharp.eu • report pro pdf
Page 1 of 1

report pro pdf

Posted: Tue Apr 11, 2017 11:04 pm
by ohernandez@sistemas-liasa.com
Hi,
Using a report with Arial font, the pdf embebed "Arial boldMT" and the pdf looks different than the printed document. Because I am documenting the operation I want the pdf document to be identical to the preview or printed document.
I try to include Arial, Arial Normal (Spanish), Arial Normal; but no success.
Any ideas?

Thanks

Oscar Hernandez

report pro pdf

Posted: Wed Apr 12, 2017 7:56 am
by robert
Oscar,

Which ReportPro ? Rp2 or Rp3, and for VO or Vulcan ?

Rp2 uses a PDF engine that I have written myself, so "everything" is possible there.
RP3 uses the WPDFControl. That will be more difficult to change.

Robert

report pro pdf

Posted: Wed Apr 12, 2017 3:15 pm
by ohernandez@sistemas-liasa.com
Robert,
I am using Rp2 with Vo.

report pro pdf

Posted: Wed Apr 12, 2017 3:50 pm
by robert
Oscar,

- Which version of VO
- Which version if ReportPro 2
- Did you buy the ReportPro source code ?
- Can you mail me the report and supporting files ?

Robert

report pro pdf

Posted: Wed Apr 12, 2017 6:26 pm
by ohernandez@sistemas-liasa.com
VO 2.8 sp4b
Rp 2.17 (June 2012)
Yes I have the source for RP2.
The report is made by code.

This is the part of the code related.
please observe the line:
oPrinter:Letrero(yy, MargenXL, gfont, 9, FALSE, MemoLine(obser, nLineLength, linobs, 4, true))
is sending "Arial" I tried several forms.

...

IF !self:oObserv:EoF
obser:= AllTrim(self:oObserv:FIELDGET(#OBSERVACIO))
nLineLength := 109
nLines := MLCount(obser, nLineLength, 4, true)
if INICIOJ + (self:Incremento * 2) >= 7.5
return PRINT_OK
endif
yy:=INICIOJ
oPrinter:DrawRectangle(yy, MargenXL, yy+self:Incremento, MARGENXR) // Recuadro
// Recuadro del titulo
oPrinter:DrawRectangle(yy, MargenXL, yy+self:Incremento, MARGENXR,,,,HS_SOLID, self:OGRIS)
oPrinter:LetreroCentrado(gfont, 9, true, yy,MargenXL, "OBSERVACIONES", self:Incremento, 7.87,ALIGN_CENTER)
yy+= (self:Incremento * 2)
FOR linobs:= linobs upto nLines
oPrinter:Letrero(yy, MargenXL, gfont, 9, FALSE, MemoLine(obser, nLineLength, linobs, 4, true))
if yy + self:Incremento < 7.5
yy += self:Incremento ELSE
exit
endif
NEXT
oPrinter:DrawRectangle(yy, MargenXL, INICIOJ, MARGENXR)
yy:= yy-INICIOJ
INICIOJ+=yy
IF linobs >= nLines
NIVEL:=13
else
return PRINT_OK
endif
ELSE
NIVEL:= 13
endif

...

METHOD
pdf.pdf
(250 KiB) Downloaded 20 times
print preview.pdf
(72.94 KiB) Downloaded 23 times
(nY,nX,cFont,nFont,lBold,cLetrero,nalignment,OTEXTCOLOR,OBKGNDCOLOR) CLASS RpPrinter

nX+=.04
nY -= .15
SELF:SetFont(cFont,nFont,lBold,FALSE,FALSE)
self:TextOut(nY,nX,cLetrero, nalignment,OTEXTCOLOR,OBKGNDCOLOR)
return nil

report pro pdf

Posted: Thu Apr 13, 2017 8:48 am
by robert
Oscar,

Since you have the source code, we should be fine. I can help you fix the code.
However, with the info that you have given me it is impossible to determine the cause of the problem.

You included a selection of your code, but in my experience the problem is often somewhere else. That is usually why you cannot find it yourself as well.

Also, you included pdf files with a scan. That does not show me what ReportPro has done, I cannot see which fonts were used.

I can understand that you do not want to send your stuff over an open forum. Please send me as much as you can to robert at xsharp dot eu.

Robert

report pro pdf

Posted: Thu Apr 13, 2017 1:27 pm
by ohernandez@sistemas-liasa.com
Thank You Robert,
I will send more info today.