Home Devices
New Blog Posts: Merging Reports - Part 1 and Part 2

RB10.06 Delphi 6.02 - PDF Printing no images

edited August 2008 in Devices
Hi

I have a slave job setup to scan a queue and produce a PDF of a report. It
all works really well except I am getting no images on the PDF. I am using
the supplied PDF device and have scoured the settings for a clue but have
not found the reason.

The images are database supplied but I also added an image onto the report
which also doesn't show (but some text I added does so I know it is the
correct version).

Now I have used my application to run the report and the image is great on
the screen and also to PDF.

Is there something I am missing here.

Code snippet

with FDataModule.clrMain do
begin
AllowPrintToFile := True;
ShowPrintDialog := False;
DeviceType := 'PDF';
TextFileName := vPDFFileName;
vDevice := 'S';

FDataModule.clrMain.PDFSettings.OptimizeImageExport := False;
//FDataModule.clrMain.PDFSettings.CompressionLevel := clNone;

vDocType := getSubtype(FReportName);;

if GetSessionParameters then
begin
SessionParameters.Items['prmUserId'].asInteger := AUsrId;
SessionParameters.Items['prmDevice'].asString := vDevice;
SessionParameters.Items['prmDocId'].asInteger := ABkgId;
SessionParameters.Items['prmDocType'].asString := vDocType;
SessionParameters.Items['prmHeader'].asString := 'Y';
if not ValidateSessionParameters then
begin
writeLog(rsReportLauncherAccessDenied);
Exit;
end;
end;

// Setup the report volume and name
volumeName := rsReportLauncherVolumeName;
reportName := FReportName;
// Make sure the report is completely refreshed
RefreshRequest := True;
// Do as the deviceType tells it
FDataModule.LastPage := 0;
print;
with FDataModule.stpAxsOne do
try
prepare;
params.paramByName('PBKGID').asInteger := ABkgId;
params.paramByName('PNOPAGES').asInteger := FDataModule.LastPage;
params.paramByName('PDOCNAME').asString := ABkgNo;
params.paramByName('PUSRID').asInteger := AUsrId;
execute;
vRetVal := params.paramByName('PSUCCESS').asString;
if vRetVal <> C_OK then
begin
writeLog(format(rsReportLauncherError,[vRetVal]));
processError(AId,format(rsReportLauncherError,[vRetVal]));
exit;
end;
except
on E: Exception do
begin
writeLog(format(rsReportLauncherError,[E.Message]));
processError(AId,format(rsReportLauncherError,[E.Message]));
exit;
end;
end;
end;
generateCRC(vPDFFileName);
generateCRC(vXMLFileName);
// Flag as processed
flagProcessed(AId);
except

Comments

  • edited August 2008
    Hi Andrew,

    Please upgrade your version of ReportBuilder to the latest (10.09) and test
    with that. Send an email to info@digital-metaphors.com with your serial
    number and purchasing email address for upgrade instructions.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited August 2008
    Nico

    Upgraded to 10.09 and no joy. Still shows no image either DB or standard.

    Works when I produce the document through the main application. I have no
    code in the report to turn off and on the images. Is there anything you can
    think of property wise that would cause this?

    regards
    Andrew




  • edited August 2008
    Hi Andrew,

    Please create a simple example I can run on my machine that demonstrates the
    issue and send it in .zip format to support@digital-metaphors.com. I'll try
    to recreate the problem on my machine and possibly track down the problem.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited August 2008
    Nico

    It would appear that the simple inclusion of ppReport in my uses clause
    allows the images to be visible.

    I discovered it because I was experimenting with PsRBExport stuff and it
    required an inclusion and then the images appeared. It used ppReport so I
    took it all out and just put ppReport and bingo it worked.

    regards
    Andrew Wood
This discussion has been closed.