Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.

Wed Sep 09, 2020 6:04 pm

Receiving the error "Length cannot be less than zero. Parameter name: length" on converting a .pdf file ti HTML.
Code snippet is :
Code: Select all
using (PdfDocument pdf = new PdfDocument())
{
    pdf.LoadFromFile(absolute-file-path);
    pdf.SaveToFile(absolute-destination-path + ".html", Spire.Pdf.FileFormat.HTML);
}

delwyn.pinto
 
Posts: 5
Joined: Wed Sep 09, 2020 1:19 pm

Thu Sep 10, 2020 5:44 am

Hello,

To help us investigate your issue more accurately, please provide the .pdf file that can reproduce your issue. You may upload your file here or send it to us ([email protected]) via email. Thanks in advance.

Sincerely,
Elena
E-iceblue support team
User avatar

Elena.Zhang
 
Posts: 279
Joined: Thu Jul 23, 2020 1:18 am

Thu Sep 10, 2020 8:18 am

Unfortunately the file cannot be shared. Can anything else be done to aid the team in this issue ?

delwyn.pinto
 
Posts: 5
Joined: Wed Sep 09, 2020 1:19 pm

Thu Sep 10, 2020 9:31 am

Hello,

Thank you for your prompt reply.
Which version of Spire.Office are you using? If you are not using the latest version (Spire.Office Platinum(Hotfix) Version:5.8.5), I recommend you download this version and test it again.

If the issue still occurs after trying, please share your file with me ([email protected]) for further analysis. Since the internal data and structure of each document are different, we need to analyze your file to locate the issue, so that we can provide you with a corresponding solution or fix. Hope you can understand.

Don’t worry, we promise to keep your document confidential and will not use them for any other purpose. Also, you can remove the security data of your file, as long as the modified file could reproduce your issue. Thanks for your cooperation.


Sincerely,
Elena
E-iceblue support team
User avatar

Elena.Zhang
 
Posts: 279
Joined: Thu Jul 23, 2020 1:18 am

Return to Spire.PDF