Get me started
CADForums.net Forum Index CADForums.net
Discussion of AutoCAD and other CAD software.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web cadforums.net
Get me started

 
Post new topic   Reply to topic    CADForums.net Forum Index -> Customization
Author Message
psilzle
Guest





Posted: Tue Oct 18, 2005 12:10 pm    Post subject: Get me started Reply with quote

I am new to lisp and was trying to write a program to check and see if
a layer "interior_loops" exists and if it does move everything on that
layer to layer 0. I need to do this for a few different layers. What
I have tried so far, tries to move the entities even if the layer does
not exist. Of course, that crashes the progam.

Any help is appriciated...

Thank you,

Paul Silzle

Back to top
Ben Gun
Guest





Posted: Tue Oct 18, 2005 4:10 pm    Post subject: Re: Get me started Reply with quote

please post what you have got so far.
ben

On 18 Oct 2005 05:04:12 -0700, "psilzle" <psilzle@bbei.com> wrote:

Quote:
I am new to lisp and was trying to write a program to check and see if
a layer "interior_loops" exists and if it does move everything on that
layer to layer 0. I need to do this for a few different layers. What
I have tried so far, tries to move the entities even if the layer does
not exist. Of course, that crashes the progam.

Any help is appriciated...

Thank you,

Paul Silzle
Back to top
psilzle
Guest





Posted: Tue Oct 18, 2005 4:10 pm    Post subject: Re: Get me started Reply with quote

I was able to achive what I wanted a different way. I just froze the
layers I didn't want changed and then changed all the remaining
entities to layer 0 and then thawed the layers that were frozen.

Thanks for checking...

Paul

Back to top
CarlB



Joined: 27 Sep 2005
Posts: 52

Posted: Tue Oct 18, 2005 6:25 pm    Post subject: re:Get me started Reply with quote

If you want to save a few steps...

(if (tblsearch "layer" "interior_loops")
(command "change" (ssget "x" '((8 . "interior_loops"))) "" " "la" "newlayername" "")
)
Back to top
View user's profile Send private message
 
Post new topic   Reply to topic    CADForums.net Forum Index -> Customization All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Windows Server DSP VoIP Electronics New Topics
Powered by phpBB