PDA

View Full Version : snapmode off/on - please help


Michael Coviello
2005-06-02, 01:30 AM
Ignore, i found thread which deals with my question

I am a beginner at this so please forgive if this is very basic.
I'm trying to write a routine which uses crossing polygon stretch.

To begin with i want to turn off osnaps
(setvar"snapmode"0)
(command "stretch" "cp")
(setvar"snapmode"1) 'then turn osnaps back on.

Osnaps come back on too quickly. Ideally, i want to have osnaps off until the stretch command is completed; allowing the user to pick as many points as they want. I'm able to get it to work but only if i know how many pauses there will be. (which you never do know).

Thanks.

fixo
2005-06-02, 04:55 PM
Maybe you can use this solution:

(setvar "osmode" 0)

Try this:

(command "_.stretch" (setq p1 (getpoint))
(setq p2 (getcorner p1)) "c"
(setq p3 (getpoint ))
(setq p4 (getcorner p3)) ""
(setq p5 (getpoint ))
(setq p6 (getpoint p5))
"")

Or better this one:

(command "_.stretch" (setq p1 (getpoint))
(setq p2 (getcorner p1)) "c"
p2
p1 ""
(setq p3 (getpoint ))
(setq p4 (getpoint p3))
"")

(setvar "osmode" 1)

Thanx

madcadder
2005-06-02, 04:59 PM
Ignore, i found thread which deals with my question

I am a beginner at this so please forgive if this is very basic.
I'm trying to write a routine which uses crossing polygon stretch.

To begin with i want to turn off osnaps
(setvar"snapmode"0)
(command "stretch" "cp")
(setvar"snapmode"1) 'then turn osnaps back on.

Osnaps come back on too quickly. Ideally, i want to have osnaps off until the stretch command is completed; allowing the user to pick as many points as they want. I'm able to get it to work but only if i know how many pauses there will be. (which you never do know).

Thanks.Play with this... it's fun and may give you ideas for your own version...
Just show us what you do with it.