GenericExtensionsToResourceManagementServiceDateFormat Method (DateTime, Boolean, Boolean) |
Converts a date time to the ISO 8601 date string required by the Resource Management Service
Namespace: Lithnet.MetadirectoryServicesAssembly: Lithnet.MetadirectoryServices (in Lithnet.MetadirectoryServices.dll) Version: 1.0.6017.24765
Syntax public static string ToResourceManagementServiceDateFormat(
this DateTime dateTime,
bool convertToUtc,
bool zeroMilliseconds
)
<ExtensionAttribute>
Public Shared Function ToResourceManagementServiceDateFormat (
dateTime As DateTime,
convertToUtc As Boolean,
zeroMilliseconds As Boolean
) As String
public:
[ExtensionAttribute]
static String^ ToResourceManagementServiceDateFormat(
DateTime dateTime,
bool convertToUtc,
bool zeroMilliseconds
)
Parameters
- dateTime
- Type: SystemDateTime
The date and time to convert - convertToUtc
- Type: SystemBoolean
A value indicating that if the date does not have a Kind of UTC, it will be converted to UTC - zeroMilliseconds
- Type: SystemBoolean
A value indicating whether the millisecond component of the date should be zeroed to avoid rounding/round-trip issues
Return Value
Type:
StringAn ISO 8601 date format string
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
DateTime. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also