Image in Report 10401

AstiniaAstinia Member Posts: 40
Hello everyone.

I have troubles with image in current report.
I've tried in new blank report - my code works perfect, but with Report 10401 it keeps be blank.
The code is on PreReport

ClientFileNAme := 'D:\_WORK_\SAve.bmp';
ServerFileName := FileManagement.UploadFileSilent(ClientFileNAme);
FileManagement.BLOBImportFromServerFile(TempBlob, ServerFileName);

TempCompanyInfo.INIT;
TempCompanyInfo.Picture := TempBlob.Blob;
TempCompanyInfo.INSERT(FALSE);

TempCompanyInfo.CALCFIELDS(Picture);


Variables

Name DataType Subtype Length
TempCompanyInfo Record Company Information
TempAttachment Record Attachment
FileManagement Codeunit File Management
ClientFileNAme Text
ServerFileName Text


TempBlob Record TempBlob


tcvdy6egiuh8.jpg

and the new report:

mwdsdbpxfned.jpg

The image itself would be another one (this is only for test purposes).

Thanks everyone!
123.jpg 262.9K
235.jpg 47.5K

Best Answer

Answers

  • Peter+is1Peter+is1 Member Posts: 174
    Hi,

    I don't have R10401 but... from the code and variables I deduce that you work with a Temporary CompanyInfo record for your test report. Does R10401 also work with a Temporary CompanyInfo record?
    If not then your code does not work for R10401.

    Good luck.
    \\
    The truth exists in seven versions.
  • TonyDuarteTonyDuarte Member Posts: 92
    Hi,

    In what part of the dataset are you adding the picture?

    Could it be a problem like that, that you don't have the picture added in the right part?
Sign In or Register to comment.