Senin, 15 Juli 2013

[ExcelVBA] A simple uptime logging worksheet?

 

Good afternoon,

I am a newby as regards VB, I know what I want to achieve but I have no
real idea how to go about it. I want to leave a worksheet open that will
autosave to keep a record of the current time and when it was opened, thus
the uptime is recorded.....

=================

Sub WaitFor(NumOfSeconds As Long)
Dim SngSec as Long
SngSec=Timer + NumOfSeconds

Do while timer < sngsec
DoEvents
Loop

End sub

=============

Called up by

Call WaitFor()

i.e Call Waitfor(60) for a delay of a minute

====

I want to have a worksheet with a GO button that copies the value of NOW()
into A1 and then waits for a minute copies the value of NOW() into A2 then
saves the worksheet then waits for a minute then repeats the write of NOW()
to A2 and saves again

When this falls over I will have the uptime and the start and end times for
the period

Is this difficult to code?

--

===========================
http://uk.linkedin.com/in/drjohnbullas

[Non-text portions of this message have been removed]

__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)
Recent Activity:
----------------------------------
Be sure to check out TechTrax Ezine for many, free Excel VBA articles! Go here: http://www.mousetrax.com/techtrax to enter the ezine, then search the ARCHIVES for EXCEL VBA.

----------------------------------
Visit our ExcelVBA group home page for more info and support files:
http://groups.yahoo.com/group/ExcelVBA

----------------------------------
More free tutorials and resources available at:
http://www.mousetrax.com

----------------------------------
.

__,_._,___

Tidak ada komentar:

Posting Komentar