Reputation: 11
We are using Viewer Autodesk via Forge to view dwf and pdf. As per your guidance: https://aps.autodesk.com/blog/dwf-and-pdf-support-forge-viewer.
What is the command or extension to view more than one sheet in dwf and/or pdf? (I have a dwf or pdf file and I want to see all the pages (sheets) contained in this file.)
Can we apply the white background in the sheet from dwf file?
Upvotes: 1
Views: 187
Reputation: 1324
You can use Autodesk.DocumentBrowser
extension which list all viewables of your document. You can access them by the hierarchy or by thumbnails.
If you want to access different viewables by code you can get them with:
var viewables = viewerDocument.getRoot().search({'type':'geometry'});
instead of doing
var defaultModel = viewerDocument.getRoot().getDefaultGeometry();
.
This will give you the list all of the views or sheets you can display in the viewer.
Then if you want to filter only 3D or 2D, you can add a role filter in the search query:
var twoDviewables = viewerDocument.getRoot().search({'type':'geometry', role: '2D'})
Upvotes: 2