Prev: Button Caption help
Next: Access 2007 Read Only Issue
From: Roger Bell on 6 Feb 2010 01:30 I have the following code in a Text Bax in a Report: =Trim("Born on" & " " & [Date of birth] & " " & ("in" & " " & [Place of Birth] & " " & Trim("and baptised this day" & " " & [Date of Baptism]))) What I would like, is to add the format command to convert the dates to dddd mmm yyyy Could anyone tell me the corrrect syntax and where this should be placed? Many thanks for any assistance.
From: John Spencer on 6 Feb 2010 07:59 You need the format function. =Trim("Born on " & Format([Date of birth],"d mmm yyyy") & " in " & [Place of Birth] & " " & Trim("and baptised this day " & Format([Date of Baptism],"d mmm yyyy")))) I'm not sure from your posting what format you actually want. "dddd d mmm yyyy" will give you Saturday 6 Feb 2010 "d mmmm yyyy" 6 February 2010 Look up the format function in VBA help for further information on formatting dates with the format command. John Spencer Access MVP 2002-2005, 2007-2010 The Hilltop Institute University of Maryland Baltimore County Roger Bell wrote: > I have the following code in a Text Bax in a Report: > > =Trim("Born on" & " " & [Date of birth] & " " & ("in" & " " & [Place of > Birth] & " " & Trim("and baptised this day" & " " & [Date of Baptism]))) > > What I would like, is to add the format command to convert the dates to dddd > mmm yyyy > > Could anyone tell me the corrrect syntax and where this should be placed? > Many thanks for any assistance.
|
Pages: 1 Prev: Button Caption help Next: Access 2007 Read Only Issue |