Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Format a text field to date

Status
Not open for further replies.

robwheels

Technical User
Jul 25, 2001
34
US
I am running a report linked to an Access database. The date field is 2008-04-10 00:00:00.000. How can I format this to 4/10/2008?

Thanks.
 
Just right click on the field on the report and click on format object. From the popup window, click on date and customize the format you want.
 
Oops. My precious post applies changing a date field to a text field with special format. For changing a text to a date and then back to text

ToText(Date((left({table.date},10)),"mm/DD/YYYY")
 
kskid,

I think you had it right the first time.

Wouldn't right-click, "Format Field...", then choose the format from the combo box be the answer?

In fact, mm/dd/yyyy is one of the standard formats offered, no?

-Dave
 
Ahhhh... now I see the thread header... a *text* field.

Interesting, though that if the data type is a date/time field in the db that Crystal would interpret that as a text field when inserted into the report??

So, robwheels, if right-click, "Format Field..." offers date formats, you're golden (i.e. use one of those). Otherwise you'll need to create a new formula field with kskid's suggestion.

-Dave
 
Thanks for the quick response.
The access field is text due to data we are manipulating. I will try the formula.
Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top