MicroStrategy ONE

Creating a link URL to specify page-by, report view, layout, or grouping for the target

The Link Editor provides a quick and easy way to link to documents and reports. For steps to create a link using the Link Editor, see Creating a link for a mobile document.

For a document on an iPhone or iPad, you can specify a report's page-by or report view, or a document's layout or grouping. For a document on an Android device, you can specify a report's report view. (The report view is whether a report is displayed as a grid, a graph, or both a grid and graph.) To specify these parameters, use the hyperlink properties and create the link URLs manually, by using the object ID and link syntax, as described below.

Prerequisites

Before creating links, create any target documents and reports, and use the following procedure to obtain their IDs:

  1. Navigate to the folder location of the report or document.

  2. Right-click the report or document, and select Properties. The Properties dialog box is displayed, with the object's ID displayed in the ID field. You can highlight and copy this ID to use in a link URL.

To create a link using a manual URL

  1. In MicroStrategy Web, open the document in Design Mode or Editable Mode.

  2. To use a text field for the hyperlink, complete the following steps (if you are adding an image, skip this step):

    1. From the Insert menu, select Text.

    2. Click in the section of the document where you want to place the text field. If you click and drag in the section, you can size the text field.

    3. To ensure that the area of a link is large enough to recognize a user selecting it, make sure it has a height and width of at least 40 pixels.

    4. Type the text to be displayed to users into the text field. You can add static text, dynamic text (in the form of data fields and auto text codes), or a combination to the text field:

      • To add static text, type the static text into the text field.

      • To add a data field, drag and drop a dataset object from the Dataset Objects panel into the text field.

      • To add an auto text code, from the Insert menu, select Auto-text, then select the code to insert.

      For background information about adding data fields and auto-text codes to documents, see the Document Creation Help.

  3. To use an image for the hyperlink, complete the following steps:

    1. From the Insert menu, select Image.

    2. Click in the section of the document where you want to place the image. If you click and drag in the section, you can size the image. The Properties and Formatting dialog box opens.

    3. To ensure that the area of a link is large enough to recognize a user selecting it, make sure it has a height and width of at least 40 pixels.

    4. Type the address of the image file to insert in the Source field.

    5. Click OK. The image appears in the document.

    6. For background information about adding images to documents, see the Document Creation Help.

  4. Right-click the image or text field, and select Properties and Formatting. The Properties and Formatting dialog box opens.

  5. From the left, click General, then select the Is Hyperlink check box.

  6. Type the link URL in the Hyperlink field:

    • To have the link execute a document, use the syntax:

    http://MSTRMobileURL?&src=source&evt=2048001&currentViewMedia=2&documentID=objectID

    • To have the link execute a report, use the syntax:

    http://MSTRMobileURL?&src=source&evt=4001&reportViewMode=view&reportID=objectID

    Replace the italicized variables, as listed in the following table:

    Variable

    Replace With

    MSTRMobileURL

    To use an absolute path to your Mobile Server, use one of the following:

    For .NET

    MobileServer/MicroStrategy/asp/Main.aspx

    For J2EE

    MobileServer/MicroStrategy/servlet/mstrWeb

    Replace Mobileserver with the name of your MicroStrategy Mobile Server.

    To use a relative path to your Mobile Server, use mstrWeb.

    source

    The page component that should handle the action and the event:

    For a document using J2EE format, mstrWeb.2048001
    For a document using .NET format, Main.aspx.2048001
    For a report using J2EE format, mstrWeb.4001
    For a report using .NET format, Main.aspx.4001

    view

    Report view mode:

    For grid view: 1
    For graph view: 2
    For grid and graph view: 3

    objectID

    The object ID of the target document or report

  7. Click OK to return to the document.

Using links to display document layouts and group data, and run reports and documents on other servers and projects

Once you have created a link to run a report or a document on an iPhone or iPad, you can add parameters to the URL to perform additional tasks, such as providing answers for prompts in the linked document, or specifying the layout to display when a document is run.

For Android and iOS devices, you can run reports or documents from a different project or server. The project or server that you link to must be defined in the mobile configuration for the device.

The table below lists the tasks you can perform, and the syntax for the link parameters to perform them. You can add these parameters to a link URL by separating each parameter with an ampersand (&). The link parameters are case sensitive. For example, the following URL contains parameters to display the first layout in a document:

Main.aspx?evt=2048001&currentViewMedia=2&documentID=E8663E7A4D8CDF05C060129D0061692&layoutIndex=0

Task

Syntax

Run a report or document from a different project or server

Server=servername&Project=projectname&uid=username&pwd=password

Replace servername, projectname, username, and password with the name of the server, project, and the login name and password to use to log in respectively.

By default, if the URL does not specify a server and project, the current server and project are used. You can specify these parameters, called session parameters, to execute a report or document in a different server or project, and provide the appropriate login name and password.

For more information on session parameters, see the Customizing MicroStrategy Web section in the Web SDK help, which is available from the SDK page in MicroStrategy Community.

Display a specific layout in a document

layoutIndex=layout

Replace layout with the number of the layout you want to display. The first layout in the document is 0, the second is 1, and so on.

Specify the group-by element in a document

groupByElements=groupByUnitID;groupByUnitType;groupByElementID

Replace the italicized variables with the following:

groupByUnitID: The ID of the group-by attribute or consolidation. You can use {&AttributeName@GUID}, to provide the ID automatically. Replace AttributeName with the name of the attribute or consolidation.
groupByUnitType: Use 12 for an attribute, or 47 for a consolidation.
groupByElementID: The ID of the group-by element. You can use {&AttributeName@LongElementID}, to provide the ID automatically. Replace AttributeName with the name of the attribute or consolidation.

You can specify multiple group-by elements by separating each set of group-by parameters with a caret (^), as follows:

groupByElements=groupByUnitID1;groupByUnitType1;groupByElementID1^groupByUnitID2;groupByUnitType2;groupByElementID2

Specify the page-by element in a report

pageByElements=pageByUnitID;pageByUnitType;pageByElementID

Replace the italicized variables with the following:

pageByUnitID: The ID of the page-by attribute or consolidation. You can use {&AttributeName@GUID}, to provide the ID automatically. Replace AttributeName with the name of the attribute or consolidation.
pageByUnitType: Use 12 for an attribute, or 47 for a consolidation.
pageByElementID: The ID of the page-by attribute or consolidation. You can use {&AttributeName@LongElementID}, to provide the ID automatically. Replace AttributeName with the name of the attribute or consolidation.

You can specify multiple page-by elements by separating each set of page-by parameters with a caret (^), as follows:

pageByElements=pageByUnitID1;pageByUnitType1;pageByElementID1^pageByUnitID2;pageByUnitType2;pageByElementID2

For information about finding the ID of an individual attribute element, see To obtain the ID of a specific attribute element in a document.

To obtain the ID of a specific attribute element in a document

  1. To obtain the ID of a specific element in an attribute, you must first obtain the ID of the attribute. Navigate to the folder location of the attribute.

  2. Right-click the attribute, then select Properties. The Properties dialog box is displayed, with the attribute's ID displayed in the ID field.

  3. Highlight the ID, then copy it to the clipboard.

  4. Open the document that contains the attribute in Editable Mode.

  5. Right-click the header of the attribute in the Grid/Graph, then point to Attribute Forms, and select ID. The ID of each element in the attribute is displayed.

  6. The full attribute element ID is the ID of the element's attribute, followed by a colon (:) and the ID of the element displayed in the grid. For example:

8D679D4B11D3E4981000E787EC6DE8A4:2