Mar 14, 2012 #1 SigAdams IS-IT--Management Sep 27, 2010 5 US For example, if I had the date 02/01/1987 Is there any way to automatically convert it to 02/01/2012? Or whatever the current year happens to be? I've tried a few things, each more clunky than the last.
For example, if I had the date 02/01/1987 Is there any way to automatically convert it to 02/01/2012? Or whatever the current year happens to be? I've tried a few things, each more clunky than the last.
Mar 14, 2012 #2 Andrzejek Programmer Jan 10, 2006 8,502 US Do you mean, convert the date in SQL? Do it in VBA? On paper? You need to be more specific. If VBA, you may try: [tt] Dim dt As Date dt = CDate("02/01/1987") MsgBox Month(dt) & Day(dt) & Year(Date) [/tt] Code not tested. Have fun. ---- Andy Upvote 0 Downvote
Do you mean, convert the date in SQL? Do it in VBA? On paper? You need to be more specific. If VBA, you may try: [tt] Dim dt As Date dt = CDate("02/01/1987") MsgBox Month(dt) & Day(dt) & Year(Date) [/tt] Code not tested. Have fun. ---- Andy
Mar 15, 2012 #3 PHV MIS Nov 8, 2002 53,708 FR You wanted this ? newDate=DateSerial(Year(Now()),Month(oldDate),Day(oldDate)) Hope This Helps, PH. FAQ219-2884 FAQ181-2886 Upvote 0 Downvote
You wanted this ? newDate=DateSerial(Year(Now()),Month(oldDate),Day(oldDate)) Hope This Helps, PH. FAQ219-2884 FAQ181-2886