LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Efficiently Pausing VBA Execution.

Hi, what I'm trying to do is have a macro run when you start excel (figured
out how to do this already) that waits for the user to enter a number into a
paticular cell in excel, then calls a function. I had an idea on how to make
it 'wait' for the value to not be null, but I fear that it won't be very
efficient as it is continuously looping until the value changes (see code
below). I have searched around and found this article, but it doesn't really
explain how you do it without the toolbar:
http://support.microsoft.com/kb/q131847/
What I would really like is a procedure that 'polls' that cell
every-so-often to see if it has changed, or does the code below every 1
second or so instead of as fast as it can possibly go (I don't think that
would be too efficient).

Private Sub test()
Dim chkA
chkA = Worksheets("Visc Table").Range("b26").Value
Do While chkA = "" 'do the below while chkA is null
chkA = Worksheets("Visc Table").Range("b26").Value
Loop
Call KODEA(chkA)
End Sub

This would work, but I'm thinking there is a better way to do it than this.
Thanks ahead of time for all the help.

- Devin L.
 
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
Can I use a pivot table with this efficiently? Darren Ingram Excel Discussion (Misc queries) 0 February 24th 09 10:08 AM
How to get 500 hyperlink address efficiently? liru Excel Discussion (Misc queries) 4 May 16th 06 03:56 AM
Getting data efficiently MAB[_6_] Excel Programming 0 September 8th 04 06:17 AM
VBA: Pausing Code Execution Michael Loganov Excel Programming 2 September 14th 03 10:53 AM
Pausing code execution Rohit Thomas Excel Programming 1 July 9th 03 10:58 PM


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