Locate coordinates


PurposeThis sample shows how to use the ArcGIS Military Analyst Coordinate Tool application programming interface (API) to convert between latitude/longitude, degrees/minutes/seconds (DMS), Universal Transverse Mercator (UTM), and Military Grid Reference System (MGRS) coordinates.

How to use

See How to use ArcGIS samples for help on compiling, setting up the debugger, and running the sample.

Data has been provided for your use with this sample. It can be found at <Your ArcGIS Developer Kit Install directory>/Samples/data/World/continents.lyr.
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.

  1. Open the solution file in Visual Studio.
  2. Click Start Debugging on the Debug menu.
  3. Click inside the data view to change the coordinate values in the associated text boxes.

Additional information

Many of the ArcGIS Military Analyst and MOLE extension application programming interface (API) objects you have used in the past have equivalent or near equivalent objects in the ArcGIS 10 ArcObjects API. These new objects should now be used and do not require a Military Analyst extension or MOLE extension license. See Migrating from Military Analyst and MOLE for information on how to accomplish tasks in ArcGIS 10 that previously required the Military Analyst and MOLE APIs.

./LocateCoordinates/LocateCoordinates.cs Form and code file.
Download the C# files
./LocateCoordinates/LocateCoordinates.vb Form and code file.
Download the VB.NET files

Download the files for all languages




Additional Requirements
  • In this sample, it is assumed that the data files are installed in the default location of \ArcGIS\DeveloperKit10.0\Samples\data. If the data files are installed in a different folder, change the file path string in the LocateCoordinates.vb/cs file.

Development licensing Deployment licensing
Engine Developer Kit: Military Analyst Engine Runtime: Military Analyst