how to poly 4 arcs

how to poly 4 arcs

devitg
Advisor Advisor
800 Views
10 Replies
Message 1 of 11

how to poly 4 arcs

devitg
Advisor
Advisor

Hi all , by tis code line I have all arcs at a given layer 

(setq arc-ss (ssget "X" '( ( 0 . "arc") ( 8 . "4-arcs"))))

 

How can I convert it to a LWPOLY or a 2dpoly ,  some like when doing a boundary, or JOIN, or PEDIT  

of course by a LISP line code , not a the command line 

devitg_1-1623691833224.png

 

 

See attached dwg 

Thanks in advance. 

 

 

 

0 Likes
Accepted solutions (1)
801 Views
10 Replies
Replies (10)
Message 2 of 11

hak_vz
Advisor
Advisor

Try this

(command "_.pedit" "m" arc-ss "" "y" "j" "" "") 

 

Miljenko Hatlak

EESignature

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
0 Likes
Message 3 of 11

devitg
Advisor
Advisor

@hak_vz Hi , after a few try and error , it seem to work 

 

(setq a (ssget "X" '( ( 0 . "arc") ( 8 . "4-arcs"))))
(VL-CMDF "_.pedit" "m" a ""  "j" "" "") 
0 Likes
Message 4 of 11

john.uhden
Mentor
Mentor

@devitg 

I'm sure glad it works, because it should, as long as the arcs begin and end at the same consecutive points.

The AutoLisp solution could be made, but it would be a lot of code.  YUCK.

John F. Uhden

0 Likes
Message 5 of 11

Kent1Cooper
Consultant
Consultant
Accepted solution

The difference between the code suggestions in Messages 2 & 3 is about whether you have the PEDITACCEPT System Variable set for PEDIT to ask whether you want to convert the Arcs to Polylines, before it lets you Join them.  You can avoid the question entirely by just using the JOIN command instead of PEDIT:

 

(initcommandversion); [because otherwise, in (command) function, doesn't work quite as doing manually]

(command "_.join" arc-ss "")

Kent Cooper, AIA
Message 6 of 11

devitg
Advisor
Advisor

@Kent1Cooper Menwhile I did the try and error , I noticed that  instead it did not join the arc it convert them to Poly 

About the PEDITACEPT , what shall be to avoid such problem 

 

Now I will test the join command , that it give me errors too , sure as I did not use the 

 

(initcommandversion)

 

Thanks 

 

 

 

0 Likes
Message 7 of 11

devitg
Advisor
Advisor

@john.uhden Hi, doing by LISP was my first intention,  as I have all the end and start point  , center radius, angles , for each arc  , so I did a LWPOLY , that result in a 4 lines , but when I start studing the SET-BULGE , I surrender with not shame. 

Soldier that surrend , worth for a new battle. 

 

 

 

 

0 Likes
Message 8 of 11

john.uhden
Mentor
Mentor
Reminds me of a joke someone told me when I was a kid...
Why are Italian war rifles in such great shape?
Never been fired and dropped only once.

It went along with things like...
The Shortest Books Ever Written:
*Great Swiss Naval Battles*
*Great German Peacemakers*
and others I shouldn't mention.

John F. Uhden

0 Likes
Message 9 of 11

Sea-Haven
Mentor
Mentor

Just a side suggestion have you looked at a pline from scratch using the arc function with various radius or is it something that the shape is random values just something that looks good ? No code only idea.

0 Likes
Message 10 of 11

devitg
Advisor
Advisor

@Sea-Haven , it was just to know how to solve in this  my particular case. 

 

 

 

 

0 Likes
Message 11 of 11

Sea-Haven
Mentor
Mentor

Thought that was the case, if Fillet 2 arcs worked would make life much easier.

0 Likes