hosyn Posted March 9, 2015 Share Posted March 9, 2015 Hello guys I need lisp code fierst select objects (ssget code ) and change lineweight to 0.05 and move them to layer yy .?? Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 9, 2015 Share Posted March 9, 2015 (edited) The user will be picking the objects themselves and not relying on the code to automatically pick the objects is that correct? Will the object(s) always be moved to layer "0"? Will the lineweight always be 0.05? Edited March 9, 2015 by ReMark Quote Link to comment Share on other sites More sharing options...
hosyn Posted March 9, 2015 Author Share Posted March 9, 2015 Yes user select objects by ssget after that code do that Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 9, 2015 Share Posted March 9, 2015 Please answer the other two questions I just added. Thank you. Quote Link to comment Share on other sites More sharing options...
tzframpton Posted March 9, 2015 Share Posted March 9, 2015 This doesn't sound like you need a LISP routine to accomplish. Using Qselect or FILTER tools can aid in the selection process, then a couple more clicks for Lineweight and Layer management. Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 9, 2015 Share Posted March 9, 2015 I too was going to suggest the same thing but lately it seems people have a fondness for not wanting to use features already native to AutoCAD. Quote Link to comment Share on other sites More sharing options...
hosyn Posted March 9, 2015 Author Share Posted March 9, 2015 This requst just a part of my lisp file 1_ we select objects after running code lisp all of objects change lineweight and layer in specifiec value I wanna do it by one commandd by lisp Quote Link to comment Share on other sites More sharing options...
tzframpton Posted March 9, 2015 Share Posted March 9, 2015 You will still have to specify lineweight and layer in the routine (sub-prompt or otherwise) so again I don't see the absolute need for a LISP routine. But obviously a routine can save one or two steps. Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 9, 2015 Share Posted March 9, 2015 (edited) This requst just a part of my lisp file1_ we select objects after running code lisp all of objects change lineweight and layer in specifiec value I wanna do it by one commandd by lisp So, the layer and the lineweight could change from drawing to drawing correct? Without the benefit of an answer to the question we cannot proceed any further. Edited March 9, 2015 by ReMark Quote Link to comment Share on other sites More sharing options...
BIGAL Posted March 10, 2015 Share Posted March 10, 2015 Posting images or example dwg's would stop people guessing and you would have your answer straight away. Quote Link to comment Share on other sites More sharing options...
hosyn Posted March 10, 2015 Author Share Posted March 10, 2015 HI BIGAL INDEED IN MY CODE I WANNA COMBINE TWO FOLLOWING (DEFUN C:SSER() (command "_SELECTSIMILAR") (command "_ERASE" "" ) ) Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 10, 2015 Share Posted March 10, 2015 That wasn't the question you originally asked. Let me refresh your memory. "I need lisp code fierst select objects (ssget code ) and change lineweight to 0.05 and move them to layer yy .??" How about you give us the information we've asked for to complete the first task BEFORE we move on to the next task? Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 10, 2015 Share Posted March 10, 2015 I must be crazy. Download the attached lisp routine I named DelSim.lsp (for delete similar). I did not write this lisp but I did amend it to include the author's name, the location where it was first posted and the date it was posted. Please leave that information intact. The author decided to invoke the program using the letters JJE. I have no idea why that was but I did not change it. DelSim.lsp Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 10, 2015 Share Posted March 10, 2015 (edited) Either I'm feeling generous or I am just plain stupid. I'm going with the latter. A very rough lisp routine that will 1) change selected objects to layer "0" and 2) change their lineweight to 0.9mm. Feel free to edit it to meet your needs. To run the program load ChgLyrWght.lsp and type the word "test" to run it. ChgLyrWght.lsp In the future it would be most helpful if you answered our questions as completely as possible. We can't help you if you do not provide us with the requested information. Do you understand? One last thing. Everything you asked about, in one way, shape or form was found with a simple Internet search. Edited March 10, 2015 by ReMark Quote Link to comment Share on other sites More sharing options...
hosyn Posted March 10, 2015 Author Share Posted March 10, 2015 Greaaatttttttttttttttt remark so thanx you send me what i need appreciate you Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.