LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
Gum Gum is offline
external usenet poster
 
Posts: 30
Default VBA adding time in milliseconds

I have this:
Now() is current time.

Function myTime()
Dim t As Variant
t = Now() + TimeValue("00:00:20")
myTime= Format(t, "hh:mm:ss") & "." & Right(Format(Timer, "#0.00"), 2)
End Function

This adds 20 seconds to now()

I require to add milliseconds to Now() rather than seconds to get mytime().
How can this be done?

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding and Subtracting a Time with MilliSeconds carl Excel Worksheet Functions 8 April 5th 23 02:41 PM
Time milliseconds format Kaykayme Excel Programming 6 October 29th 08 05:44 PM
Comparing time values which have milliseconds in them e.g 10:20:30 Jon Stickings Excel Discussion (Misc queries) 5 October 5th 06 02:03 PM
Can time be measured to milliseconds? Pflugs Excel Programming 2 June 22nd 06 12:40 AM
Grab Time with milliseconds included in VBA Erick Excel Programming 4 October 28th 04 10:42 AM


All times are GMT +1. The time now is 06:56 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"