ArcGIS Pro 3.1 API Reference Guide
ArcGIS.Desktop.Core.UnitFormats Namespace / DisplayUnitFormats Class / GetProjectUnitFormats Method
The type of unit format list to return

In This Topic
    GetProjectUnitFormats Method (DisplayUnitFormats)
    In This Topic
    Get the current list of unit formats in the current project for the given UnitFormatType. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    public IList<DisplayUnitFormat> GetProjectUnitFormats( 
       UnitFormatType unitFormat
    )
    Public Function GetProjectUnitFormats( _
       ByVal unitFormat As UnitFormatType _
    ) As IList(Of DisplayUnitFormat)

    Parameters

    unitFormat
    The type of unit format list to return

    Return Value

    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run
    Remarks
    The list can vary between projects. If there is no project open the list returned is the current default application list (for the given unitFormat).
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.0 or higher.
    See Also