Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Private Sub cmdstartimer2_Click()
startClock2 End Sub Public Sub startClock2() Dim start Range("F7").Select start = Timer Do While stopped = False DoEvents Worksheets("Stopw").Range("F5").Value = Int((Timer - start + 0.5) / 60) Worksheets("Stopw").Range("H5").Value = (Timer - start) Mod 60 Worksheets("Stopw").Range("I5").Value = (Timer - start + 0.5) - (Int(Timer - start + 0.5)) Worksheets("Stopw").Range("D5").Value = Int((Timer - start + 0.5) / 3600) Loop End Sub I am using this VBA Code to start a timer process. I Can run more than one, but not simultaneously, and also I need a process to stop the timer. Can anyone help??? Thanks (in advance) |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Check out Chip Pearson's http://www.cpearson.com/excel/ontime.htm
As far as running multiple routines goes, it is possible but I would not recommend it since XL/VBA are not designed with multi-threading in mind. -- Regards, Tushar Mehta www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity solutions In article , Paul23 @discussions.microsoft.com says... Private Sub cmdstartimer2_Click() startClock2 End Sub Public Sub startClock2() Dim start Range("F7").Select start = Timer Do While stopped = False DoEvents Worksheets("Stopw").Range("F5").Value = Int((Timer - start + 0.5) / 60) Worksheets("Stopw").Range("H5").Value = (Timer - start) Mod 60 Worksheets("Stopw").Range("I5").Value = (Timer - start + 0.5) - (Int(Timer - start + 0.5)) Worksheets("Stopw").Range("D5").Value = Int((Timer - start + 0.5) / 3600) Loop End Sub I am using this VBA Code to start a timer process. I Can run more than one, but not simultaneously, and also I need a process to stop the timer. Can anyone help??? Thanks (in advance) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? | Excel Discussion (Misc queries) | |||
Delete row wise duplicates & colomun wise simultaneously excel | Excel Worksheet Functions | |||
How do i create a running total in Excel? | Excel Discussion (Misc queries) | |||
How do I set up an automatic running average in Excel | Excel Worksheet Functions | |||
Excel 2000 running on Windows XP SP2 does not properly open CSV fi | Excel Discussion (Misc queries) |