Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
Valued Contributor
sunchase
Posts: 51
Registered: ‎10-06-2008
Message 1 of 2 (125 Views)

Stop when ESC is pressed

125 Views, 1 Replies
03-27-2009 04:40 AM
Hi!

I made a little programme, that demonstrates Monte Carlo method. In this I would like to use a while loop, so it draws points until user presses ESC or ENTER.
How can I do this? What I've tried so far just made an error when ESC was pressed.

Thx for your help!
*Expert Elite*
scot-65
Posts: 2,210
Registered: ‎12-11-2003
Message 2 of 2 (125 Views)

Re: Stop when ESC is pressed

03-27-2009 02:50 PM in reply to: sunchase
(while (> (getvar "cmdactive") 0) (command pause) );while

???
Scot-65
Dyslexia is a permanent physical disability that cannot be seen.
Introverts is proof that there is indeed intelligent life on this planet.
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.