Author Topic: Pause Script for User Input?  (Read 6487 times)

0 Members and 1 Guest are viewing this topic.

M-dub

  • Guest
Re: Pause Script for User Input?
« Reply #15 on: May 28, 2008, 11:38:21 AM »
I have to get to this later on tonight.  I just had a bit of down-time and thought I'd ponder that problem a bit.

Thanks guys!  :)

M-dub

  • Guest
Re: Pause Script for User Input?
« Reply #16 on: May 30, 2008, 09:05:45 AM »
Ok, so I'm going to try to write a lisp to do what I need to do.  Here goes...

- Select entities to be deleted via window / crossing
- Insert block at user defined point & populate attributes via small script

First of all, does it sound doable?

daron

  • Guest
Re: Pause Script for User Input?
« Reply #17 on: May 30, 2008, 09:20:35 AM »
Would this help?
Quote
DELAY

Provides a timed pause within a script

 Command entry: delay (or 'delay for transparent use)
Enter delay time (in milliseconds): Enter a value from 0 through 32,767 milliseconds

Specifies the duration of a pause. Entering delay 1000 in your script delays the start of execution of the next command for about one second. The longest delay available is 32767, which is slightly less than 33 seconds.


M-dub

  • Guest
Re: Pause Script for User Input?
« Reply #18 on: May 30, 2008, 09:25:21 AM »
I guess I should try that first... I had read that, but didn't think it would allow for user input.  Will try that first, as it would be exactly what I'm looking for.

daron

  • Guest
Re: Pause Script for User Input?
« Reply #19 on: May 30, 2008, 09:27:25 AM »
Ok, so I'm going to try to write a lisp to do what I need to do.  Here goes...

- Select entities to be deleted via window / crossing
- Insert block at user defined point & populate attributes via small script

First of all, does it sound doable?
Code: [Select]
(defun c:doable (/ ss blck pt rt)
(setq ss (ssget))
(command "_.erase" ss "")
(setq blck (getfiled "What Block" "" ".dwg" 8)
(setq pt (getpoint "\nSelect insertion point: "))
(setq rt (getpoint pt "\nSelect rotation angle: "))
(command "_.insert" blck pt rt)
(princ)
)
Totally untested and written right here in the comment panel.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Pause Script for User Input?
« Reply #20 on: May 30, 2008, 09:31:34 AM »
Would this help?
Quote
DELAY

Provides a timed pause within a script

 Command entry: delay (or 'delay for transparent use)
Enter delay time (in milliseconds): Enter a value from 0 through 32,767 milliseconds

Specifies the duration of a pause. Entering delay 1000 in your script delays the start of execution of the next command for about one second. The longest delay available is 32767, which is slightly less than 33 seconds.


Daron,

The DELAY command is typically used when one has created a slides show with a script.
Be your Best


Michael Farrell
http://primeservicesglobal.com/

M-dub

  • Guest
Re: Pause Script for User Input?
« Reply #21 on: May 30, 2008, 11:36:53 AM »
I'm getting there.  :)

Without even using lisp...

A combination of macros and script.

daron

  • Guest
Re: Pause Script for User Input?
« Reply #22 on: May 30, 2008, 11:54:50 AM »
Oh. It's been too long since I've done anything with scripts or slides. I was just going on what if. Glad it's coming around for you Mike.