Madmarty
2008-07-19, 09:13 PM
Hello everyone, in my office, we just about always work on a massive hospital, of course we always use the same wall thicknesses when we can. I am working on a lisp to quicken my drafting, I'm tired of typing in:
ff (for offset) 4-7/8 SPACE
ff 4-1/4 SPACE
ff 5/8 SPACE
ff 2 1/8 SPACE
ff 4-7/8 SPACE
It can go on like this for a while when your drawing a renovation or addition on this huge hospital. I used that cool MDOFF.LSP from Glen Johnston to get me started (Thank You Glen), but I only know how to tell lisp to ask me how far i want the distances to be, I want it to be 5/8" or 4-7/8" every time I run it. Here's what I've tried:
(defun c:sw ()
(setq oldcmdecho (getvar "cmdecho"))
(setvar "cmdecho" 0)
(setq oldoffset (getvar "offsetdist"))
(setq ent (entsel "\nPick the line: "))
(setq side (getpoint "\nPick an offset side: "))
(setq dist (5/8 ))
(setvar "offsetdist" dist)
(command "offset" "" ent side "")
(setvar "cmdecho" oldcmdecho)
(setvar "offsetdist" oldoffset)
(princ)
)
Any help with that dist **** would be helpful.
Marty
Moderator Note:
Please use [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code)
ff (for offset) 4-7/8 SPACE
ff 4-1/4 SPACE
ff 5/8 SPACE
ff 2 1/8 SPACE
ff 4-7/8 SPACE
It can go on like this for a while when your drawing a renovation or addition on this huge hospital. I used that cool MDOFF.LSP from Glen Johnston to get me started (Thank You Glen), but I only know how to tell lisp to ask me how far i want the distances to be, I want it to be 5/8" or 4-7/8" every time I run it. Here's what I've tried:
(defun c:sw ()
(setq oldcmdecho (getvar "cmdecho"))
(setvar "cmdecho" 0)
(setq oldoffset (getvar "offsetdist"))
(setq ent (entsel "\nPick the line: "))
(setq side (getpoint "\nPick an offset side: "))
(setq dist (5/8 ))
(setvar "offsetdist" dist)
(command "offset" "" ent side "")
(setvar "cmdecho" oldcmdecho)
(setvar "offsetdist" oldoffset)
(princ)
)
Any help with that dist **** would be helpful.
Marty
Moderator Note:
Please use [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code)