ArcGIS Pro 3.2 API Reference Guide
ArcGIS.Core.Data Namespace / SQLSyntax Class / Format Method / Format(DateOnly,SQLDateTimeType) Method
The value to format.
The type of formatting to perform.

In This Topic
    Format(DateOnly,SQLDateTimeType) Method
    In This Topic
    Formats the dateOnly value into a literal string in the format specified by dateTimeType. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    Public Overloads Function Format( _
       ByVal dateOnly As DateOnly, _
       ByVal dateTimeType As SQLDateTimeType _
    ) As String

    Parameters

    dateOnly
    The value to format.
    dateTimeType
    The type of formatting to perform.

    Return Value

    The formatted DateTime literal string.
    Exceptions
    ExceptionDescription
    dateTimeType is not a field of SQLDateTimeType.
    A geodatabase-related exception has occurred.
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.2 or higher.
    See Also