I’m testing the Aspose.Word and Aspose.Pdf products for conversion between the two formats.
I can load the Doc, and export to XML, but when i try to Bind the XML to the new Pdf document, i get the following System.IO.Exception:
"The path is too long after being fully qualified. Make sure path is less than 260 characters."
I’ve attached the original Doc so you can try to duplicate the problem…
Thank you for considering Aspose.
I can’t reproduce this error. Can you please post your code here? Please also tell me the path of the xml.
Here’s the code i’m using :
Document wordObj = new Document(@“D:\Projects\EPMon\Análise\Caderno de Encargos.doc”);
FileStream fs = new FileStream(@“D:\Encargos.pdf”, FileMode.Create);
Pdf pdfObj = new Pdf(fs);
StreamReader tr = new StreamReader(@“D:\Encargos.xml”);
string xml = tr.ReadToEnd();
The solution for the project i’m trying this on is on
so the binaries would be on
as you can see, i tried shortening the directory of the xml file to the shortest one possible, but still i would get the same error.
Thank you for considering Aspose.Pdf.
As you can see in Writing Pdf directly , some advanced features such as hyperlink is not supported in Direct-to-File mode. So please use normal mode to convert Word to Pdf.
Please also note that the first parameter of BindXML is the xml file path but not the content of the xml.
Thanks. I’ve at least got it working now, with simpler Docs.
I knew it had to be something really simpler.
Ok. Different problem.
I’ve corrected the path problem, and created a new word document (Using Word 2003), and wrote the word “test” in it. (Simplest test there is, huh?)
The resulting PDF has the text “Se$1,S’6=test” on it. I know i’m using the “demo” version of the software, but somehow that doesn’t seem like it ought to be happening. I’ve included the original doc for you to try and replicate the problem
I have tested it and found no error. The garbage characters are part of the watermark of Aspose.Word.