Public Function GetAvailableLocationUnitFormats() As IList(Of DisplayUnitFormat)
public IList<DisplayUnitFormat> GetAvailableLocationUnitFormats()
Public Function GetAvailableLocationUnitFormats() As IList(Of DisplayUnitFormat)
public IList<DisplayUnitFormat> GetAvailableLocationUnitFormats()
| Exception | Description |
|---|---|
| ArcGIS.Core.CalledOnWrongThreadException | This method or property must be called within the lambda passed to QueuedTask.Run. |
{
//Linear location unit formats are not included if the map sr
//is geographic.
//Note: Must be on the QueuedTask.Run()
var loc_units = map.GetAvailableLocationUnitFormats();
}
{
//Get the list of available location unit formats
//for the current map
//Note: Must be on the QueuedTask.Run()
var loc_units = map.GetAvailableLocationUnitFormats();
//arbitrarily use the last unit in the list
map.SetLocationUnitFormat(loc_units.Last());
}
Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)