Converting Excel file to PDF using MS Graph API and SharePoint

Allen Conquest 6 Reputation points

I am programmatically converting Excel files to PDF, but uploading them to SharePoint, and then downloading in a PDF format. This has been working fine, but I now have an issue trying to convert a large Excel file. It has about 2007 rows, and when converted using Excel 365 creates a 462 page PDF.

When I try to convert this file programmatically, I get this error: XLSPageLimitExceeded

I presume this means I'm exceeding some limit to the number of pages. But I am unable to find this limit documented anywhere.

Could you please point me to where this limit (and any others are documented), or let me know what this limit is, and others, such as file size.

Thank you,


Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
10,852 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Deva-MSFT 2,256 Reputation points Microsoft Employee

  2. GorkaG 1 Reputation point

    Hi @Deva-MSFT ,
    We have the same problem, many excel files give that error when converting to PDF. (XLSPageLimitExceeded)
    The specifications and limits mentioned before, are only for the normal use of excel in sharepoint, and excel online, but are not related with the conversion to PDF with MS Graph.
    There is any guide or specifications with the limits for this type of conversion to PDF?, if we will have that problem is important to know when and why it will happen.

    0 comments No comments

  3. David Burg 406 Reputation points Microsoft Employee

    The page limit is 250 pages. Beyond this count of pages, you will see XLSPageLimitExceeded error.

    0 comments No comments