Cast a database date to a nullable UTC date that will be serialised correctly by JSON without affecting the date, i.e., just changes the DateTimeKind to 'UTC' without affecting the date but removing the time if necessary (although this function should not be passed a date containing a time).

<para> Use when passing dates such as Account History Item Dates and Effective Dates from Script Code to an HTML Widget's template text in the form of a JSON object. </para> <para> This is a shortcut to Runtime.DateUtilities.CastToUtcDate. </para>

Syntax

finHtmlWidgetUtilities.GetNullableJsonUtcDateFromDatabaseDate(value)

Parameters

NameTypeOptionalByRefDescription
value Date? A nullable Date. If this does not have a Kind of 'Unspecified', a trace warning will occur.

Return Value

Date?

A nullable Date value.

Member of:
finHtmlWidgetUtilities
Namespace:
Intersoft.finSupport6
Assembly:
finSupport6, Version=6.0.3
Target Framework:
.NET 9.0