Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Timer
Any way to have the time it takes to run a procedure
appear somewhere? Perhaps on the status bar? Start = Timer Finish = Timer Application.StatusBar = TotalTime = Finish - Start TIA! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Timer
Try this: Dim Start As Date, Finish As Date Start = Now ' Procedure Finish = Now Application.StatusBar = "Time taken=" & Format((finish - Start), "ss") HTH Helen |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Timer
Thanks for the response. Unfortunately, I get a syntax
error for the code for the last line below.......... Dim Start As Date, Finish As Date Start = Now Range("br3").Select Application.ScreenUpdating = False While ActiveCell < "" If ActiveCell + ActiveCell.Offset(0, 1) < 1 Then ActiveCell.EntireRow.Delete ActiveCell.Offset(-1, 0).Select End If ActiveCell.Offset(1, 0).Select Wend Application.ScreenUpdating = True Finish = Now ************Syntax Error*********** Application.StatusBar = "Time taken=" & Format((Finish - Start), "ss") End Sub -----Original Message----- Try this: Dim Start As Date, Finish As Date Start = Now ' Procedure Finish = Now Application.StatusBar = "Time taken=" & Format((finish - Start), "ss") HTH Helen . |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Timer
sr
The syntax is correct. The two lines under your error should be one line. They probably got wrapped in the message. -- Dick Kusleika MVP - Excel www.dicks-clicks.com Post all replies to the newsgroup. "sr" wrote in message ... Thanks for the response. Unfortunately, I get a syntax error for the code for the last line below.......... Dim Start As Date, Finish As Date Start = Now Range("br3").Select Application.ScreenUpdating = False While ActiveCell < "" If ActiveCell + ActiveCell.Offset(0, 1) < 1 Then ActiveCell.EntireRow.Delete ActiveCell.Offset(-1, 0).Select End If ActiveCell.Offset(1, 0).Select Wend Application.ScreenUpdating = True Finish = Now ************Syntax Error*********** Application.StatusBar = "Time taken=" & Format((Finish - Start), "ss") End Sub -----Original Message----- Try this: Dim Start As Date, Finish As Date Start = Now ' Procedure Finish = Now Application.StatusBar = "Time taken=" & Format((finish - Start), "ss") HTH Helen . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
TIMER | Excel Discussion (Misc queries) | |||
Timer | Excel Discussion (Misc queries) | |||
Timer | Excel Worksheet Functions | |||
Lap-timer | Excel Discussion (Misc queries) | |||
Stopping a Timer / Running a timer simultaneously on Excel | Excel Discussion (Misc queries) |