Hello, I was testing the sample with the given test folder. It had a htm file in it and also a txt. When I rid of the filter in plugin and ran the plugin in Acrobat, it could not convert the txt and htm files into PDF. Is there any way to do so for these file types?
The same AVConversion APIs will handle those formats as well.
Thank you for answering.
I noticed that the sample uses AVConversionConvertToPDF method, but it is not successful for the txt and htm files inside the test folder. Does the "conversion handler" that AVConversionConvertToPDF uses not convert those two type? Am I suppose to use a different method and approach it differently than what the sample has?
No, AVConversionConvertToPDF hould work fine.
What error(s) are getting returned when you try the text and HTML file?
Okay. I found out that the conversion return kAVConversionSuccessAsync. When I get rid of the block that return to continue the function inside the if, it crashed Acrobat after I ran the plugin.
Fixed it. I set kAVConversionASyncOkay to kAVConversionNoFlags to disallow asynchronous conversion. Thank you
There weren't any specific error. Rather, a message box "Cannot convert the file." There is an if statement to see if the conversion was successful. If not, the message box appears and get out of the function.
Can you convert the file in Adobe Acrobat?
Yes. Acrobat manually convert those files successfully.