Why pdf converting to doc results 0 of file size of the output?

Hi,Support:
I use PdfDocument.save(SaveFile ,Aspose.Pdf.SaveFormat.DocX) based on VB.net and API version 23.4, however, the file size of SaveFile is 0. What’s wrong? How to sucessfully convert pdf to doc?
Thanks for you help!

@ducaisoft

Can you please share your sample source PDF for our reference? We will test the scenario in our environment and address it accordingly.

For any pdf file, the file size of the output doc is always 0 by using Pdf.save(DocFile, SaveFormat.docx), whereas the result is right by using Doc.save(Pdffile,saveformat.docx).

@ducaisoft

If it means that you are trying to process/save a Word file using Aspose.PDF, it would not work as Aspose.PDF does not support manipulation of Word documents. However, it is unable to generate a valid output Word file from an input PDF at your end, we need some more details because we are unable to notice this issue in our environment.

Yes!
For any pdf file, the file size of the output doc is always 0 by using Pdf.save(PdfFile, SaveFormat.docx), Pdf.save(PdfFile, SaveFormat.doc), Pdf.save(PdfFile, SaveFormat.tex), whereas the result is right by using Doc.save(PdfFile,saveformat.docx),Doc.save(PdfFile,saveformat.doc),
Doc.save(PdfFile,saveformat.text).
I do not know what’s wrong.

@ducaisoft

Please try to use below complete code snippet and with the latest version of the API and let us know if you still face any issues:

Document pdfDocument = new Document(dataDir + @"samplePDf.pdf");
DocSaveOptions saveOptions = new DocSaveOptions();
saveOptions.Format = DocSaveOptions.DocFormat.Doc;
saveOptions.Mode = DocSaveOptions.RecognitionMode.Flow;
pdfDocument.Save(dataDir + @"samplePDf.doc", saveOptions);

I try the Pdf.dll version 23.10, it throws an exception saying “System.NullReferenceException” when performing Pdf.save(WordDocFilename,SaveOps), What’s wrong?

@ducaisoft

Did you try using it with a valid or 30-days free temporary license? Are you using it in an environment where all windows fonts are installed and present? Please share a sample PDF for our reference so that we can also try to replicate this issue in our environment and address it accordingly.

I use a trial api, for any pdf, it always throw this exception.

@ducaisoft

Please use the API with a valid license and let us know if it is throwing any exception even after using a valid license.

I have no valid lincense or 30-day temperary lincense for this version,therefor, I can not test again.

@ducaisoft

You can request an extension or new temporary license in our Purchase forum in case you want to evaluate the latest version of the API. Our sales team will assist you accordingly.