Convert DOCX, XLSX, PPTX and PDF files to TIFF images in .NET on Azure Storage using Aspose REST APIs transient error

Hi there,


I am experiencing transient errors with the cloud API. I am using the cloud API to convert DOCX, XLSX, PPTX and PDF files to tiff images. I am experiencing the following problems:

DOCX and XLSX

The tiff returned from the service is blank. A tiff with the expected dimensions returned, but it’s transparent.

PPTX

The API returns a message saying "An attempt was made to move the position before the beginning of the stream."

PDF

When converting a PDF document, the API returns a message saying “Incorect file format” (the word ‘incorrect’ is spelled incorrectly in the error message).

Attached are the 4 files that I’ve used for testing. As previously stated, the errors are all transient. I have managed to successfully convert all of the files.

I would really appreciate help in resolving these problems.

Regards,


Neil Grobler

Hi Neil,


neil.grobler:

DOCX and XLSX

The tiff returned from the service is blank. A tiff with the expected dimensions returned, but it’s transparent.

Thanks for the template files

Aspose.Cells for Cloud SDK converts your attached XLSX file fine as I tested with the following sample code:

e.g

Sample code:


//Save as TIFF

APPKey.AppSID = "7xxxxxxxxxxxxxxxxxxxxxxxx";

APPKey.AppKey = "3xxxxxxxxxxxxxxxxxxxxxx";


//build URI

string strURI = "http://api.aspose.com/v1.1/cells/Demo_Spreadsheet.xlsx?format=TIFF";

//sign URI

string signedURI = Sign(strURI);


using (HttpWebResponse response = GET(signedURI))

{

using (var stream = File.Create(@"e:\test2\outDemo_Spreadsheet1.tiff"))

{

response.GetResponseStream().CopyTo(stream);

}

}


//OR

//get response stream

// Stream responseStream = ProcessCommand(signedURI, "GET");

// using (Stream fileStream = System.IO.File.OpenWrite("e:\\test2\\out1asdfasdfasdf1.tiff"))

// {

// CopyStream(responseStream, fileStream);

// }

// responseStream.Close();


I have attached the output TIFF file for your reference.


I think as you find this issue temporarily, and you are also able to convert your Excel file to TIFF format successfully. But we need to evaluate it on our end. For your information, there was an issue affecting URL Signing for customers using our PHP/Ruby customers due to a possible bug within the SDK and we believe this issue is fixed now.


Thank you.

Hi Neil,


Thanks for your inquiry. In addition to what Amjad said, we also managed to successfully convert your .docx to .tiff format using Aspose.Words for Cloud API. The service is currently running fine. I have attached the converted .tiff file here for your reference. We will further test your remaining .pptx and .pdf files and get back to you soon.

Best regards,

Hi Neil,

Can you please share your email ID registered with your cloud account? Please also share at what time you last noticed this issue and how frequently you notice this issue.

Best Regards,

Thanks for getting back to me so quickly.


I just wanted to clarify, I am also able to successfully convert all of the sample files, but the problem is that they don’t convert every time. i.e. if I convert the same file 10 times, it converts properly maybe 7 out of the 10 times.

I am running the conversion on files hosted in Azure, so the file names are different, but the files themselves are identical.

My account ID is neil@vidleos.com. You can see the exact times on the history page (Dashboard).

Please let me know if there is anything else I can do to assist, and please feel free to contact my directly by email.

Hi Neil,

Thanks for the details. We are investigating what went wrong at your end and let you know once our investigation is complete.

Can you please also share which development platform are you using?

Best Regards,

The solution I’m working on is built with .net 4.5. The interaction with the Apose cloud API all happens from an Azure worker role, but I’m experiencing the same behaviour in a console application running on my development machine.

Hi Neil,

Thanks for more details. The issue is still under investigation. No other customer has reported such issue so it is specific to your account. We will share more details as soon as our development team finds what went wrong with those calls.

Best Regards,

I think I’ve found the source of the problem. The files for conversion are being copied to a separate storage account before the conversion takes place, and the call to the Apose cloud API is sometimes being made before the copy operation completes.


Please accept my sincerest apologies for the inconvenience this has caused, and thank you again for your help in resolving this issue.

Hi Neil,

Good to know that you were able to catch this and thanks for sharing these details with us.

Best Regards,