←Select platform

DateToString Method

Summary
Converts a date time to a string.
Syntax
C#
Objective-C
C++/CLI
Java
Python
public static string DateToString( 
   DateTime value 
) 
NSString* dateToString:(NSDate*)date; 
public static String dateToString(Date value) 
public:  
   static String^ DateToString( 
      DateTime^ value 
   ) 
def DateToString(self,value): 

Parameters

value
The date time value to be converted.

Return Value

A string representation of  value that can be converted back to a date.

Remarks

DateToString converts a date value to a universal ISO string value. In the .NET platform, this is performed using the "s" format specifier and in the JavaScript platform this is performed using the ToISOString method.

The string value can be converted back to a date using DateFromString.

DateToString and DateFromString can be used to convert a date value to and from a string. The conversion uses a universal ISO time format (the "s" format specifier in .NET and ToISOString in JavaScript).

These methods are used when serializing and de-serializing date values such as when an annotation container is saved or loaded from the disk. the data value is converted to a string during serialization (saving) and then converted back from string during deserialization (loading).

For example, DateToString and DateFromString are used when saving and loading AnnReview.Date values.

Requirements

Target Platforms

See Also

Reference

AnnObject Class

AnnObject Members

Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Annotations.Engine Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.