Preview first 2 pages

Go to solution
New Contributor

Preview first 2 pages

I wanted to check if there is any API which I can use to display first 2 or 3 pages of document uploaded on box? it can be PDF or word or PPT. so originally it can have 10 pages but in preview i want to show first 2 or  pages only

Box Employee

Re: Preview first 2 pages

This isn't supported at the moment. If you're using the Preview component (, you can fork the code and modify behavior yourself by adding something like:


Object.defineProperty(doc, 'numPages', { value: Math.min(doc.numPages, 2) });