Skip to main content

Legend Image

Comments

4 comments

  • Permanently deleted user

    'Export Map' activity does not return a image of the Legend as you know.

    I would check 'Print Map' activity.

    0
  • Permanently deleted user

    Thanks for the response but I don't want to use a print template. I just want access to the Legend image.

    0
  • Permanently deleted user

    So how about making a Print Template that is for legend items only.

    Configure it to have a image format output option.

    Then use Print Map for that and use that image (of the legend) for your following purpose.

    Regards

    Ralph

    0
  • Permanently deleted user

    The following steps were taken to generate an image of a Map Legend.

    Open Geocortex Report Designer to create a print template that shows a map and a legend:

     

    1. Open the Geocortex Essentials controls from the bottom left of the controls panel.

     

    2. Drag Main Map and Legend controls into the Detail 1 section of the report and position them where you would like them to be.

     

    3. In order for the Legend image to draw, a Main Map control must be used with it, however we are going to hide the map so it won’t be shown.  Highlight the Main Map control and set the visibility to “False” in the properties box.

     

    4. Save the report to a location your Essentials site can access and make note of the file name. Example: C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\Default\REST Elements\Sites\<Site Name>

    Add the new print template to a Geocortex Essentials site:

     

    1. Log into Essentials Manager choose a site to work with then click Print Template from the navigation pane.

     

    2. Click the Add Print Template button and enter a Display Name and a description of what this report will generate.

     

    3. Choose the .rpx file saved from step 4 above.

     

    4. On the details tab, change output format of template to an image format you need. I chose .png Click Apply Details.

     

    5. Click hyperlink icon next to “Edit Print Template” to view REST Endpoint and make note of the ID number next to the Print Template text at top of screen.  Example: Mine was (ID:2)

    Open Workflow Editor to create a workflow that prints a map using the new template. 

     

    1. Drag the PrintMap activity into the Sequence box.

     

    2. In the “Print Template Id” field, enter the number of the template id noted from step 5 above and enter it between double quotes. Example: “2”

     

    3. Click in the “Result Url” field then double click Create Variable from the pick list. This will ensure you create the correct variable type.

     

    4. Create a variable name to store the Url the PrintMap activity generates.  This variable will get placed into the “Result Url” field automatically.

     

    5. Drag on a DisplayHyperlink activity into the Sequence box and place it below the PrintMap activity.

     

    6. Enter the variable name created in step 3 above without quotes.

     

    7. Enter some text in double quotes that the user will click on to open the image in a new browser tab. Example: “Get Image”

     

    8. Enter a title and a message for the dialogue box that will open notifying the user that the image is ready to access.  Example: “Your legend is ready to open” and “Click the link to open your image in a new browser tab”

     

    9. Save the workflow to a location your Essentials site can access and make note of the file name. Example: C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\Default\REST Elements\Sites\<Site Name>

    Add the Workflow to the “I want to…” menu in your site.  Open Essentials Manager

     

    1. Click the Workflows link in the navigation pane then click the Add Workflow button

     

    2. Enter a display name and an ID.  Make note of the ID you create. Example: ID: Map_Legend

     

    3. Click the Browse… button to locate the workflow file you saved in step 9 above.  Highlight and click OK. Click Next then Finish.

     

    4. Click the Viewers link in the navigation pane.

     

    5. Choose a Viewer to add the workflow to and click the edit icon.

     

    6. Click the I Want To menu from the navigation pane then click the Add Menu Item button

     

    7. Enter the text you want to show up in the I Want to Menu into the “Text: “ field.

     

    8. Enter “RunWorkflowById” in the command field.

     

    9. Enter the ID you noted in step 2 above into the “Command Parameter: “ field.

     

    10. Enter a detailed description of what the command will do. Then click OK

     

    11. Apply changes, then Save Site.

    Run Workflow by launching the Viewer and selecting command from the ”I want to menu...“ This will open a dialogue box with a hyperlink which opens the maps legend in a new browser tab as a .png file.  Right click on the image and choose “Save As” to save it to a folder on your hard drive.

    0

Please sign in to leave a comment.