Home page
 
 Home 
 ASP 
 PHP 
 SQL 
 HTML 
 JavaScript 
 Search 
 Contact 
 
Search
or browse popular tags
Access Functions
Subscription

Sign up for the free email newsletter for new tips, tutorials and more. Enter your email address below, and then click the button.

Privacy Policy

RSS Twitter

Access: IsDate Function

Print

In Access, the IsDate function returns a value indicating whether or not a variant argument can be converted to a date.

The syntax for the IsDate function is:

IsDate ( expression )

The required expression argument is a date expression or string expression recognizable as a date or time.

Example

IsDate (#10/5/2006#)        returns TRUE
IsDate("It's a date")       returns FALSE
IsDate("May 25, 2006")      returns TRUE

VBA Code

Dim MyResult as Boolean 
MyResult = IsDate("It's a date")

The IsDate function can be also used in VBA code. Now the MyResult variable would contain FALSE as a value.

SQL query

You can also use the IsDate function in a query.

SELECT IsDate([FirstName]) AS Expr1, IsDate([BirthDate]) AS Expr2, IsDate(#10/10/2000#) AS Expr3
FROM EmployeeAddressTable


If you'd like to see how it works, enter SQL statement and press Execute
 




Tags:

Add To: Add to dzone dzone | Digg this digg | Add to del.icio.us del.icio.us | Stumble it stumbleupon

  • Comments





Copyright © 2005-2014             www.WebCheatSheet.com All Rights Reserved.