MIMEType and Params for embedded XML

Hello

How can I set MIMEType and add Params after embedding an XML in PDF. Both properties are empty.

Aspose.Pdf.Document pdfDocument = new Aspose.Pdf.Document(“test.pdf”);
Aspose.Pdf.FileSpecification fs = new Aspose.Pdf.FileSpecification(“any.xml”, “My XML File”);
pdfDocument.EmbeddedFiles.Add(fs);

Thanks
Stephan

Hi Stephan,


Thanks for contacting support.

You do not need to specify the MIME while embedding files inside PDF documents. However can you please share some details regarding your requirement on specifying MIME type while embedding XML/other files etc.

PS, is it because you need to embed files with MIME so that when files are extracted, they are appropriate information/type associated with them.

I have an example PDF with follow properties. I want to create a new PDF with same properties. But these properties are read only. How can I set thisI have an example PDF with follow properties. I want to create a new PDF with same properties. But these properties are read only. How can I set this.

MIMEType = text/xml

Params
- CheckSum = null
- CreationDate = 01.01.0001 00:00:00
- ModDate = 06.11.2013 14:12:36
- Size = -1

Hi Stephan,


Thanks for sharing the details.

As per my observations, you need to add XMP Metadata information for PDF document. For further details, please visit Set XMP Metadata in a PDF File