How to use
See How to use ArcGIS samples for help on running the sample. If the sample has associated data, you will find that the sample's zip file includes a "data" folder alongside the language folders. However, you will need to update the sample to point to the location of the data once you have extracted all the files.
- Start the sample application.
- Click Open to load a map document into the PageLayout control.
- Click the Map Surrounds toolbar menu. NorthArrow, ScaleBar and ScaleText are listed.
- Click NorthArrow and drag a rectangle on the page layout frame. A dialog box populated with various types of north arrow symbols opens.
- Click a north arrow and click OK. The north arrow is added to the page layout.
- Repeat steps 3, 4, and 5 using ScaleBar and ScaleText to add a scale bar and scale text to the page layout.
Download the files for Java
symbologybean/AddMapSurrounds.java | Loads a frame with Map, TOC, and Toolbar controls, and a toolbar menu with different map surrounds as menu items. |
symbologybean/tools/NorthArrowTool.java | Creates a custom tool to handle various mouse events and calls SymbologyFrame when NorthArrow is clicked. |
symbologybean/tools/CreateScaleBarTool.java | Creates a custom tool to handle various mouse events and calls SymbologyFrame when ScaleBar is clicked. |
symbologybean/tools/CreateScaleTextTool.java | Creates a custom tool to handle various mouse events and calls SymbologyFrame when ScaleText is clicked. |
symbologybean/ui/SymbologyFrame.java | Opens a dialog box with north arrow, scale bar, or scale text symbols (depending on the item clicked on the toolbar menu). |
Development licensing | Deployment licensing |
---|---|
Engine Developer Kit | Engine Runtime |
ArcView | |
ArcEditor | |
ArcInfo |