![]() |
Won't Work with Excel'97 - What Will Q
The following line of code will not work with Excel'97 but will work on
later versions (goes into Debug - Invalid procedure) Sheets("Access Log").Cells(x + 2, 1) = Format(Now(), "ddd dd/mm/yy at hh:mm:ss ampm ") Does anyone know code for above formatting that will work with Excel'97 and above? Thanks |
Won't Work with Excel'97 - What Will Q
Hi,
if you want to display "at" as it is, try this: Sheets("Access Log").Cells(x + 2, 1) = _ Format(Now(), "ddd dd/mm/yy ""at"" hh:mm:ss ampm ") the later versions seem to be less strict. see also the help topic or web page. User-Defined Numeric Formats (Format Function) http://msdn.microsoft.com/library/en...ricformats.asp -- HTH, okaizawa John wrote: The following line of code will not work with Excel'97 but will work on later versions (goes into Debug - Invalid procedure) Sheets("Access Log").Cells(x + 2, 1) = Format(Now(), "ddd dd/mm/yy at hh:mm:ss ampm ") Does anyone know code for above formatting that will work with Excel'97 and above? Thanks |
Won't Work with Excel'97 - What Will Q
Thanks for that, it works. It would have taken light years for me to spot
that one "okaizawa" wrote in message ... Hi, if you want to display "at" as it is, try this: Sheets("Access Log").Cells(x + 2, 1) = _ Format(Now(), "ddd dd/mm/yy ""at"" hh:mm:ss ampm ") the later versions seem to be less strict. see also the help topic or web page. User-Defined Numeric Formats (Format Function) http://msdn.microsoft.com/library/en...ricformats.asp -- HTH, okaizawa John wrote: The following line of code will not work with Excel'97 but will work on later versions (goes into Debug - Invalid procedure) Sheets("Access Log").Cells(x + 2, 1) = Format(Now(), "ddd dd/mm/yy at hh:mm:ss ampm ") Does anyone know code for above formatting that will work with Excel'97 and above? Thanks |
All times are GMT +1. The time now is 11:20 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com