Code Red > AutoLISP (Vanilla / Visual)

HOUSTON I HAVE A PROBLEM !!!

(1/2) > >>

pryzmm:
hi, again

i have this lisp from another site, that is really ok, but now i wanted the same lisp to do a different command
instead of its original intent, its from "offset" to "stretch" command,


;;orig code start here;
;;---------------------------------------------------------------

(defun C:OffPoly1 ()
(setq polypick (cadr (entsel "Select Polyline Segment to Offset: ")))
(command "_.explode" polypick)
(setq pieces (ssget "P"))
(command "_.offset" pause polypick pause "");; i needed this string to use command:stretch, be able to do the selection, from pt1 to pt2, exit stretch when done and proceed with the next command below....
(command "_.pedit" "m" pieces "" "y" "j" "" "")
); end defun

;;--------------------------------------------------------------

im a newbie in this coding stuff so could gurus/ jedi or anyone have a look and tweak this for me plsssss...  :-(


thank you in advance,,,  :lol:


<edit: author of code is Kent Cooper
http://discussion.autodesk.com/thread.jspa?threadID=648301
>

deegeecees:
Jedi... ...now THATS comedy!

CAB:
If all you want to do is stretch then why the explode?

Perhaps if you define exactly what you want to accomplish we could better assist you.

pryzmm:

--- Quote from: CAB on April 15, 2008, 12:07:11 AM ---If all you want to do is stretch then why the explode?

Perhaps if you define exactly what you want to accomplish we could better assist you.



--- End quote ---

hi cab, glad you drop by  :-D ,,,,i have a p-line drawing of a "stair cross section" as shown in the attached drawing file (stair.dwg)
my intention is to explode the p-line stair as shown in the "before" drawing, so i can amend the riser by using "stretch command" (25mm inward) as
nosing, as shown in the "after" drawing and then make the entire lines (those that i exploded) to be p-line again, the original lisp can do a
a similar job but only it uses offset, i needed it to do the explanation above.   :|

i hope i made it clear to you guys,,,,, thanks for any help !!!   :-)


Bob Wahr:
I'm confused why you need a program to do this.


--- Quote ---Command: s STRETCH
Select objects to stretch by crossing-window or crossing-polygon...
Select objects: cp
First polygon point:
Specify endpoint of line or [Undo]:  <Ortho off>  <Osnap off>
Specify endpoint of line or [Undo]:
Specify endpoint of line or [Undo]:
Specify endpoint of line or [Undo]:  2 found

Select objects:
Specify base point or [Displacement] <Displacement>:
Specify second point or <use first point as displacement>: @25<180

Command:
--- End quote ---

Navigation

[0] Message Index

[#] Next page

Go to full version