Hi I used the following code to change the system date to a string like "000923" for 23rd,sept 2000, however when I try this code on another computer gives me "002309". What's the cause of it? How can I modify my code to adapt different types of system date? Thanks!
Code:strDate = Right(Date, 2) & IIf( _ Len(Mid(Date, InStr(1, Date, "/") + 1, InStrRev(Date, "/") - InStr(1, Date, "/") - 1)) = 1, "0" & _ Mid(Date, InStr(1, Date, "/") + 1, InStrRev(Date, "/") - InStr(1, Date, "/") - 1), Mid( _ Date, InStr(1, Date, "/") + 1, InStrRev(Date, "/") - InStr(1, Date, "/") - 1)) & Left( _ Date, 2)




Reply With Quote