A Complicated Date String Conversion

CharlesWhiteman

Registered User.
Local time
Today, 23:23
Joined
Feb 26, 2007
Messages
421
I have the following date/time string

2006-03-08-00.00.00.000000

I need to convert it into

08/03/2006

Any advice most appriciated
 
How about

DateValue(Left("2006-03-08-00.00.00.000000",10))
 
Or for a field:

MyDate:DateValue(Left([FieldNameHere],10))
 
thanks Bob :-) - I worked out that I needed an expression name:

So I've got this

DocDateVal: DateValue(Left([DocumentDate],10))

Now I'm going to hunt down a solution for where there are NULL values
 
I am trying this the following but getting a bit stuck:
DocDateVal: =IIF([DocumentDate] Is Not Null, DateValue(Left([DocumentDate]),10), 0)
 
GOT IT !!

DocDateVal: IIf([DocumentDate] Is Not Null,DateValue(Left([DocumentDate],10)),"")
 
Is there a way to make DateValue display

6 March 2006 instead of 6/3/2006

Thanks
 
Is there a way to make DateValue display

6 March 2006 instead of 6/3/2006

Thanks

Code:
DocDateVal: IIf([DocumentDate] Is Not Null,[COLOR=red]Format([/COLOR]DateValue(Left([DocumentDate],10))[COLOR=red],"d mmmm yyyy")[/COLOR],"")
 

Users who are viewing this thread

Back
Top Bottom