LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 60
Default Workaround for com exe timer?? help

I am going for 30 minutes. My understanding is that the default for time is
seconds; Is this true? Then i would need 1800 seconds asking that no other
processes run.

Also, for the record, KICKIT goes back to the beginning of the SQL Query
request. I am asking that all further processes are suspended and if the
query is not sucessful to restart it after 30 minutes.

Intuitively this has me a little worried since i have already declared the
variables. Do I have to set them to nothing before I declare them again?

Thank you,
Nicole

"Jim Cone" wrote:

Nicole,
Maybe this is what you want...
'---------------
Dim c As Integer, startTimer As Single
c = 0
startTimer = Timer

Do While c = 0
If Range("A2") < "" Then c = 1
If c = 1 Then Exit Do
If Timer startTimer + 30 Then GoTo KickIt
Loop
KickIt:
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"Nicole Seibert"

wrote in message
Hi fellow helpers,
I created this little ditty so that I wouldn't have to write the far more
complex
ActiveX exe (and because I have never written an ActiveX exe). The problem
is I get an error with the following code on the starttime = now line.

Dim c As Integer, starttimer As Integer

c = 0
starttimer = Now() (I have also tried this: starttimer = Format(Now,
"h:mm:ss"))

Do While c = 0
If Range("A2") < "" Then c = 1
If c = 1 Then Exit Do
If Now starttimer + TimeValue("0, 30, 0") Then GoTo KICKIT
Loop

I think what is happening is that starttimer may be continually updating to
reflect "NOW", but I don't want it to do this. Is there a way to capture
current time without it updating?

Thanks,
Nicole

 
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
I have a workaround Lyle Miller Excel Worksheet Functions 0 March 31st 10 05:49 PM
Workaround no COUNTIFS in 2003 fay Excel Worksheet Functions 5 November 10th 09 04:14 AM
Help with circular reference. Need workaround Corey Excel Worksheet Functions 3 December 15th 06 07:02 PM
Stopping a Timer / Running a timer simultaneously on Excel Paul23 Excel Discussion (Misc queries) 1 March 10th 06 12:08 PM
csv load 64K workaround r0dr1g0 Excel Worksheet Functions 1 March 7th 05 06:36 PM


All times are GMT +1. The time now is 06:34 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"