I get dates in my dataset in the form of "yyyyMMdd" (that is, 20080228 means February 28, 2008)
I need to convert them to "M / d / yyyy"
Examples:
20080228 = 2/28/2008
20080101 = 1/1/2008
20081001 = 10/1/2008
20081212 = 12/12/2008
Which correct expression should handle this?
EDIT
The expression I used (ORDDTE is in the format "yyyyMMdd" and I have a switch for the Spanish or English date format):
=CDate(Mid(First(Fields!ORDDTE.Value, "ReturnTagHeader").ToString(), 5, 2) + "/" + Right(First(Fields!ORDDTE.Value, "ReturnTagHeader").ToString(), 2) + "/" + Left(First(Fields!ORDDTE.Value, "ReturnTagHeader").ToString(), 4)).ToString(IIf(Parameters!Language.Value = "ES", "d/M/yyyy", "M/d/yyyy"))
source
share