Free Support Forum - aspose.cloud

Pdf conversion error


#1

Hi - I can convert .doc,.txt etc to jpg with cloud api no problem.


However, when i try to convert a single page pdf to jpg I get:

{“Message”:“Format ‘jpg’ is not supported.”}

The pdf’s are put to the cloud correctly, so the problem is the conversion.

Here is the code:

String format = “jpg”;
String storage = “”;
String folder = “”;
String outPath = “”;

storageApi .PutCreate(docToBeConverted, “”, “”, new File(docToBeConverted));

com.aspose.pdf.model.ResponseMessage response =
pdfApi.GetDocumentWithFormat(docToBeConverted, format,storage, folder, outPath);

As a final question, will a multi page pdf be converted to one large jpg is I also just use the above code with a multi-page pdf?

Many Thanks.
Barry

#2

barrychoc:
Hi - I can convert .doc,.txt etc to jpg with cloud api no problem.

However, when i try to convert a single page pdf to jpg I get:

{“Message”:“Format ‘jpg’ is not supported.”}

The pdf’s are put to the cloud correctly, so the problem is the conversion.

Here is the code:

String format = “jpg”;
String storage = “”;
String folder = “”;
String outPath = “”;

storageApi .PutCreate(docToBeConverted, “”, “”, new File(docToBeConverted));

com.aspose.pdf.model.ResponseMessage response =
pdfApi.GetDocumentWithFormat(docToBeConverted, format,storage, folder, outPath);
Hi Barry,

Thanks for contacting support.

Please share the resource file, so that we can test the scenario in our environment.

barrychoc:
As a final question, will a multi page pdf be converted to one large jpg is I also just use the above code with a multi-page pdf?
When converting multi-page PDF to JPEG, each page is converted to individual JPEG image.