question

PeterBlack-0581 avatar image
0 Votes"
PeterBlack-0581 asked saldana-msft edited

File limits in PDF generation using Microsoft Graph API

We are converting an Excel file to PDF by uploading to SharePoint using the Graph API, then downloading using format=pdf. This has been working fine for most files, but fails for a spreadsheet with 2007 rows (317kb in size). When converted manually in Excel 365 the file produces a PDF of 462 pages. Clearly we can alter the settings we pass to reduce the number of pages, but it would be helpful to understand what the service API limits are (given it does actually work in Excel 365).

The API request we're using is:

theInputStream = theGraphClient.sites(aSiteId).drives(myDrive.id) .items(theUploadedItem.id).content().buildRequest(requestOptions).get();

The error log contains the error XLSPageLimitExceeded. Can anyone explain what the value of the limit is? Also, Is there a limitation for the generation for:

  1. File size

  2. Number of rows

  3. Number of columns

  4. Number of cells

  5. Number of sheets

Or anything else? Thanks so much!




microsoft-graph-filesmicrosoft-graph-sites-lists
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

Deva-MSFT avatar image
0 Votes"
Deva-MSFT answered PeterBlack-0581 commented

Adding a similar thread which i answered it earlier!!


· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi Dave
Apologies, as I hadn’t realised that a colleague had asked the same question. As he said, the link you provided is for Excel and we’re really talking about limits that seem to be imposed by the graph API. Thanks for trying to help, though.

0 Votes 0 ·