Overview:
Build a scale bar for a pre-existing print template.
Solution:
Building a scale bar for your print template requires three steps:
Build a scale bar for a pre-existing print template.
Solution:
Building a scale bar for your print template requires three steps:
- Configure the Scale Bar control
- Configure the Scale Bar Distance control
- Configure the Print Template ScaleBar Units
Scale bars work with a Main Map control. Your print template will need to have a Main Map control in order for the scale bar to function correctly
Configuring the Scale Bar control:
- Expand the Geocortex Essentials toolbox panel and drag a Scale Bar control onto the design surface.
- Expand the Controls toolbox panel and then place a Shape control on the design surface so that its left edge touches the right side of the Scale Bar control.
- Select the Shape control and in the Properties area, on the right side of the screen, set Size to 1.0 , 0.15 inches
- Drag another Shape control and position its left edge to touch the right edge of the last Shape Control.
- Select the new Shape control and in the Properties area set the BackColour property to Black and the Size to 0.5, 0.15 inches.
- Place a third Shape control with its left edge touching the right edge of the last Shape control.
- In the Properties area, set the Size of the latest Shape control to 0.5, 0.15 inches
- Save the print template.
Configure the Scale Bar Distance control:
- Drag the Scale Bar Distance control above the Scale Bar control. Align the left edge of the Scale Bar Distance control with that of the Scale Bar control.
- Select the Scale Bar Distance control and in the Properties panel set OutputFormat to that of your choice.
- Drag a Label control so that it is left aligned above where the ScaleBar Control and Shape Control meet.
- Select the Label control and in the Properties area, set the Text to "0".
- Left align a second Scale Bar Distance control above where second and third Shape controls meet. In this case, we want the Label control to display a value that is half the distance of first Scale Bar Distance control. To accomplish this, a Calculated Field is required.
- Expand the Fields component in the Report Explorer on the right side of the window.
- Right-click on Calculated, then click Add.
- Select the new Field and in the Properties area set Name to HalfDistanceCalc, and Formula to _ScaleBarDistance/2
- Select the second Scale Bar Distance control. In the Properties panel, set OutputFormat to a format of your choosing. Then, set Datafield to HalfDistanceCalc, Text to Distance/2 and Name to HalfDistance.
- Drag a third Scale Bar Distance control above the right edge of the last Shape control.
- Set the OutputFormat property for the third Scale Bar Distance control to a format of your choice.
- Place a Scale Bar Units control in the design area with its left edge touching the right edge of the third Scale Bar Distance control.
Your scale bar should look similar to the following: - Save the print template.
Configure the Print Template Scale Bar Units:
- Open your site in Essentials Manager and then Edit the Print Template that you are adding the Scale Bar to.
- Click the drop down menu for Scalebar Units and select the unit of your choice.
- Apply Details and Save Site, then launch the print template in the viewer.
Comments
0 comments
Article is closed for comments.