Property EnableTimestampOffsetSupport
EnableTimestampOffsetSupport
Gets or sets a value indicating whether TimestampOffset fields are supported, which necessarily changes the behavior of Date fields.
Declaration
public static bool EnableTimestampOffsetSupport { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean | A value indicating whether TimestampOffset fields are supported, which necessarily changes the behavior of Date fields. |
Remarks
ArcGIS Maps SDK historically allowed using either DateTime or DateTimeOffset values
for fields of type "Date". To support TimestampOffset fields and avoid ambiguity, the behavior
of Date fields has changed to only use DateTime values. This new behavior is now enabled by default,
so TimestampOffset fields are supported by default. For more information, see
https://links.esri.com/DotNetDateTime.
To disable support for TimestampOffset fields and revert to the previous behavior, set this property to false
when initializing the app.
When EnableTimestampOffsetSupport is false:
- Values of Date attributes are returned as
DateTimeOffset(UTC). - Values of TimestampOffset attributes are also returned as
DateTimeOffset. - Either
DateTimeorDateTimeOffsetvalues can be used when editing Date fields. - Editing data with TimestampOffset fields is not supported. A System.NotSupportedException will be thrown.
- Creating TimestampOffset fields, domains, renderers, or Arcade expressions is not supported.
When EnableTimestampOffsetSupport is true (default):
-
Values of Date attributes are returned as
DateTime(UTC). Using aDateTimeOffsetfor a Date field will cause a "Geodatabase data type mismatch" exception. - Values of TimestampOffset attributes are returned as
DateTimeOffset. - Only
DateTimevalues can be used to edit Date attributes. They are converted to UTC. DateTimeOffsetvalues can be used to edit TimestampOffset fields.- Creating TimestampOffset fields, domains, renderers, and Arcade expressions is supported.
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 200.4 - 200.8 |
| .NET | 200.4 - 200.8 |
| .NET Windows | 200.4 - 200.8 |
| .NET Android | 200.4 - 200.8 |
| .NET iOS | 200.4 - 200.8 |
| .NET Framework | 200.4 - 200.8 |
| UWP | 200.4 - 200.8 |