Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
User-driven abort?
Hi all, I have a procedure that randomizes data until certain criteria are met Those criteria are user-driven, and if they enter in criteria that ar too "tight" it could take a very long time for the randomization loop to compelte (and it's possible that they will NEVER compelte if th criteria are set too high) I'm using the status bar to show a loop count number (otherwise I hav screenupdating set to false), but would like to instead have some sor of message box that shows the current loop count value and a big fa "Abort" button that lets the user stop the loop without usin crtl-break Is this even possible in excel VBA? If it matters, screenupdating mus be false, else the time it takes to execute a loop is too dependant o how fast the user's machine can redraw the data as it's randomized -- Ouk ----------------------------------------------------------------------- Ouka's Profile: http://www.excelforum.com/member.php...fo&userid=2398 View this thread: http://www.excelforum.com/showthread.php?threadid=50661 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
User-driven abort?
In a tight loop, a button could be troublesome.
Look at the EnableCancelKey property of the application.Object -- Regards, Tom Ogilvy "Ouka" wrote in message ... Hi all, I have a procedure that randomizes data until certain criteria are met. Those criteria are user-driven, and if they enter in criteria that are too "tight" it could take a very long time for the randomization loops to compelte (and it's possible that they will NEVER compelte if the criteria are set too high) I'm using the status bar to show a loop count number (otherwise I have screenupdating set to false), but would like to instead have some sort of message box that shows the current loop count value and a big fat "Abort" button that lets the user stop the loop without using crtl-break Is this even possible in excel VBA? If it matters, screenupdating must be false, else the time it takes to execute a loop is too dependant on how fast the user's machine can redraw the data as it's randomized. -- Ouka ------------------------------------------------------------------------ Ouka's Profile: http://www.excelforum.com/member.php...o&userid=23988 View this thread: http://www.excelforum.com/showthread...hreadid=506612 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Abort recursion | Excel Programming | |||
user event driven macro issue | Excel Programming | |||
user event driven macro issue | Excel Programming | |||
Abort or continue | Excel Programming | |||
Abort or continue | Excel Programming |