Menu

#92 Error error on extracting of XML attachments

0.1.2.1
open
nobody
None
5
2021-08-29
2021-08-29
Leo Chapiro
No

Hi, I'm new in this forum. I use the PDFClown in my project in order to extract every attachments, possibly include in a PDF and got an error on some special ZUGFeRD PDFs (PDFs with a XML meta datas inside).
I think I found the error, anyway I can extract the attachment now (after fixing), there is the point (FullFileSpecification.cs):

/*
Gets the embedded file associated to the given key.

/
private EmbeddedFile GetEmbeddedFile(PdfName key)
{
PdfDictionary embeddedFilesObject = null;

    try
    {
        // Leo, 27.08.2021
       embeddedFilesObject = (PdfDictionary)BaseDictionary[PdfName.EF].Resolve();

        //embeddedFilesObject = (PdfDictionary)BaseDictionary[PdfName.EF];
    }
    catch(Exception ex)
    {

    }

 if(embeddedFilesObject == null)
    return null;

return EmbeddedFile.Wrap(embeddedFilesObject[key]);

}

1 Attachments

Discussion


Log in to post a comment.

MongoDB Logo MongoDB