Click to Rate and Give Feedback
MSDN
MSDN Library
.NET Development
.NET Framework 3.5
ASP.NET Reference
Client Reference
Global Namespace
Date Type Functions
 parseInvariant Function

  Switch on low bandwidth view
This page is specific to
Microsoft Visual Studio 2008/.NET Framework 3.5

Other versions are also available for the following:
Date.parseInvariant Function

Creates a date from a string by using the invariant culture. This function is static and can be invoked without creating an instance of the object.

var a = Date.parseInvariant(value, formats);
value

A string that represents a date.

formats

(Optional) An array of custom formats.

If value is a valid string representation of a date in the invariant format, an object of type Date; otherwise, null.

Exception type

Condition

Sys.ArgumentException

(Debug) formats contains an invalid format.

Use the parseInvariant function to create an object of type Date from a string. The EnableScriptGlobalization()()() property of the ScriptManager control has no effect on this function.

Reference

Other Resources

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker