Method: Timer for VBS
- Updated2024-09-12
- 1 minute(s) read
Methods > Method: Timer for VBS
Method: Timer for VBS
Specifies the number of seconds that have passed since midnight.
vTimer = Object.Timer
| Object | VBS Object with this method. You do not need to specify this object. |
| vTimer | Variant Receives the number of seconds that have passed since midnight. |
The following example determines the time it takes to iterate a loop:
Dim StartTime, I, Elapsed, iCount StartTime = Timer For I = 1 to 1000000 iCount = iCount +1 Next Elapsed = Timer - StartTime Call MsgBox("Elapsed Seconds: " & Elapsed, vbInformation)
See Also
Related Topics
DateAdd | DateDiff | DatePart | DateSerial | DateValue | Date | Day | Hour | Minute | MonthName | Month | Now | Second | TimeSerial | TimeValue | Time | Timer | Weekday | WeekdayName | Year