EducationSoftwareStrategy.com
StrategyCommunity

Knowledge Base

Product

Community

Knowledge Base

TopicsBrowse ArticlesDeveloper Zone

Product

Download SoftwareProduct DocumentationSecurity Hub

Education

Tutorial VideosSolution GalleryEducation courses

Community

GuidelinesGrandmastersEvents
x_social-icon_white.svglinkedin_social-icon_white.svg
Strategy logoCommunity

© Strategy Inc. All Rights Reserved.

LegalTerms of UsePrivacy Policy
  1. Home
  2. Topics

KB248665: How to export the current document with currently selected panels to PDF in MicroStrategy Web 9.4.1 using URL API/Javascript


Community Admin

• Strategy


How to export the current document with currently selected panels to PDF in MicroStrategy Web 9.4.1 using URL API/Javascript

Users are able to export the current document to PDF with the currently selected panels using the toolbar export to PDF icon.
If the toolbar is not available to end users the following methods can be used to export the document to PDF with the current panel selections using an object on the document template:
 
1. Express View Mode
The following URL API syntax can be used to export the current document including the currently selected panels in Express View mode:
ASPx:


Main.aspx?evt=3069&src=Main.aspx.3069&executionMode=3&messageID={&DOCUMENTMESSAGEID}

JSP:
 

mstrWeb?evt=3069&src=mstrWeb.3069&executionMode=3&messageID={&DOCUMENTMESSAGEID}

 
Create a textbox or image and enable the hyperlink property to implement the link URL above.
 
2. Interactive View Mode
Interactive View Mode works different from Express View Mode for which reason the above URL API cannot be applied. In order to achieve the same behavior it is required to trigger the export using Javascript as shown below:
a. Insert a HTML container
b. Insert the following JavaScript syntax:

<html>
<head>
<script language="JavaScript">
<!--
  function myFunction() {
    if(typeof Strategy!=="undefined"){Strategy.getViewerBone().commands.exec("export", "3");}else{alert('This action is not supported in the current view mode');};
  }
//-->
</script>
</head>
<body>
<a href="javascript:myFunction()">Export</a>
</body>
</html>

c. When running the document in Interactive View Mode, the HTML container shows a link "Export" that, as soon as it is clicked, triggers the export to PDF with currently selected panels.
 


Comment

0 comments

Details

Knowledge Article

Published:

March 31, 2017

Last Updated:

March 31, 2017