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

KB14281: How to use dynamic content from a grid report in a Control Document in MicroStrategy Narrowcast Server 9.x


Community Admin

• Strategy


In MicroStrategy Narrowcast Server 9.x - 10.x, it is possible to use dynamic content from a grid report inside a Control Document. This document will follow an example which uses a File ITM control document to dynamically add a region name to the file name when it is written.

In Strategy Narrowcast Server 9.x - 10.x, it is possible to use dynamic content from a grid report inside a Control Document. A Control Document, also called an Execution Control Document, is a plaintext document containing information formatted to a specific syntax which allows various message properties to be set or overwritten. Each Information Transmission Module (ITM) has its own list of allowed properties and the syntax to use for each of them.
 
This document will follow an example which uses a File ITM control document to dynamically add a region name to the file name when it is written. This technique can be used to add dynamic content from a Strategy grid report to any of the properties allowed by any of the ITMs in a control document. The procedure of this functionality requires the Strategy grid report to follow a strict setup format. The following example will be broken into two sections, setting up the Strategy grid report via Strategy Developer 9.x - 10.x and setting up the Strategy Narrowcast Server 9.x - 10.x Control Document.
 
Setting up the Strategy grid report:

  • Only one attribute is allowed on the report and it must be placed on the columns.
  • Only one result is allowed to be displayed, as attempting to display multiple results will cause a temporary delivery failure due to incorrect syntax. Filters or prompts may be used to limit the results. In this example, a simple attribute element list filter will suffice, as shown below:
ka04W000001MKouQAG_0EM440000002Bbf.jpeg
  • NOTE: The use of prompts can provide the ability to personalize the control documents just as standard Strategy reports and documents can be personalized in Strategy Narrowcast Server 
  • Save and close the report.

 
Setting up the Strategy Narrowcast Server service:

  • Create a new service that will send to a file.
  • On the Message contents page, click on Define Saved Documents to select the Strategy report or document to save. By default, the file will be saved with the name 'My Saved Documents' and then the appropriate extension. In this example, a simple Strategy grid report was selected and is being saved as a PDF file, as shown below:
ka04W000001MKouQAG_0EM440000002Bbo.jpeg
  • NOTE: The filename can be changed at this point, but only static text can be written. Also, the file extension cannot be changed.
  • Check the 'Show advanced content sections' checkbox, located at the bottom of the content window, to enable the usage of control documents, as shown below:
ka04W000001MKouQAG_0EM440000002Bbd.jpeg
  • Click 'Define Execution Control (Advanced)' to create a new control document.
  • Replace the text with the correct syntax for the property to be set or modified. In this case, the following syntax will change the name of the saved document:
    SaveDocumentAs='NAME_AS_DISPLAYED_IN_content_SECTION.pdf=NEW_NAME.pdf'
     
  • To enable the dynamic content, create an information object using the Strategy grid report created according to the steps above in the location where the text is to be displayed. If the information object is not personalized, then simply selecting the report is all that is needed. If the report is to be personalized, then the appropriate Advanced Options should be set.
ka04W000001MKouQAG_0EM440000002Bbm.jpeg
  • NOTE: The default XSL used for the IO works fine. Changing the XSL used to format the IO could cause the file name to be displayed incorrectly.
  • Click 'Return to Service Wizard'.
  • Finish creating the service by creating or selecting an existing Subscription Set and Schedule.

 
When the service is run, the dynamic content will be inserted into the text. In the example, the filename will look as follows:

ka04W000001MKouQAG_0EM440000002Bbi.jpeg

 
Refer to the following Strategy Knowledge Base technical notes and documents for more information:

  • KB11180 : How to rename SMTP attachments using a control document in Strategy Narrowcast Server 9.x
  • KB12378 : How to save attachments created by a service with the same name as the report referenced in the attachment in Strategy Narrowcast Server 9.x
  • KB9877 : How to use Execution Control Documents to add the current day's date to the File Name in a service using the File ITM with Strategy Narrowcast Server 9.x

Comment

0 comments

Details

Knowledge Article

Published:

April 6, 2017

Last Updated:

April 6, 2017