Wilder1626
asked on
Date and time format issue
Hello all
I'm trying to add the date and time of the day in the same cell in this macro:
But the result in the cell is only: 21-10-2011.
How can i make it look like 21-10-2011 08:29 AM?
Thanks for your help
I'm trying to add the date and time of the day in the same cell in this macro:
If Not r Is Nothing Then
If r.Value > "" And r.Offset(, 28) = "" Then
r.Offset(, 26).Value = Application.UserName
r.Offset(, 27).NumberFormat = Date & " " & "[$-F400]h:mm AM/PM"
r.Offset(, 27).Value = Date
End If
End If
But the result in the cell is only: 21-10-2011.
How can i make it look like 21-10-2011 08:29 AM?
Thanks for your help
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
perfect.
Thanks, it work
Thanks, it work
Open in new window