Description This function shows the file in the Panorama Viewer i.e. the div for which the ID you have set to Panorama-Viewer. The file name is read from the PanoramaAPI.fileName property. In case of multipage documents, the page number is read from PanoramaAPI.currentPageNumber property. The application is a JavaScript Promise. Below is a sample structure how to chain multiple functions in JavaScript Promise.
PanoramaAPI.currentPageNumber = 1;
PanoramaAPI.fileName= "Your_File_Name.Extension"; 
PanoramaAPI.getShowFileJSON().then(function (data){
            if (data.message == "File_Not_Found"){
            alert("Could not find the requested file. Please check if the file exists in your server");
            }
            CallYourFunction();
            }).catch(function (error){
                console.log("Error Message:", error);
            }); 
Syntax PanoramaAPI.getShowFileJSON().then(function (d) {})
Parameters NA
Returns NA

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Post Comment