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!

Keeping leading zeros from month and day. 1

Status
Not open for further replies.

bbart

MIS
May 3, 2001
12
US
I need to keep the leading zeros in the date when I use Datepart. I am trying to pull the month and day from a date field. I also tried Left() Right() and Mid(), but they ignore the leading zeros.

Please help.

Thanks,
Brian Bartley
 
Hi
Would this suit (?):
Format(DatePart("d", Date), "00")
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top