Acad_2010_user_NL Posted August 19, 2010 Posted August 19, 2010 Hi, I want to change all text of a layer to a layer with -text for example if i have some text in layer 1 then i want it in layer 1-text and text of layer 2 in layer 2-text. I want to use it in a script file so i need a command i can use for it, does a command like that exists? thx R Quote
autolisp Posted August 19, 2010 Posted August 19, 2010 Hi, I want to change all text of a layer to a layer with -text for example if i have some text in layer 1 then i want it in layer 1-text and text of layer 2 in layer 2-text. I want to use it in a script file so i need a command i can use for it, does a command like that exists? thx R dear use filter command Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 I dont whant to use filter because you get a screen and i want to let the script run from start to finish without doing anything so is there another solution ? thx Quote
migs Posted August 19, 2010 Posted August 19, 2010 Would it not be easier to just freeze everything excluding the current layer (layer 1) select the objects showing and then place them onto the desired layer (1-text) I know there is a LISP that will move all text onto a desired layer but i guess thats not really what your looking for Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 You can use this, but don't forget to add your desire Layer Name. (sssetfirst nil (ssget "_x" '((0 . "TEXT,MTEXT")(8 . "YourLayerName")))) Regards, Tharwat Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 i can use that lisp in my script if you got it :wink: and freezing is an option to but first whant to try it this way Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 i can use that lisp in my script if you got it :wink: and freezing is an option to but first whant to try it this way Use it in the Command Line of Autocad. Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 (sssetfirst nil (ssget "_x" '((0 . "TEXT,MTEXT")(8 . "level 1")))) i entered this but it doesn't do anything what im doing wrong ??? Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 if i do this: (sssetfirst nil (ssget "_x" '((0 . "TEXT,MTEXT")(8 . "level 1-text")))) it doesn't work either Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 (sssetfirst nil (ssget "_x" '((0 . "TEXT,MTEXT")(8 . "level 1")))) i entered this but it doesn't do anything what im doing wrong ??? The space that you have between level.....1 Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 but that is the layer name Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 but that is the layer name But Layer name do not except spaces within right? Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 my layers does have spaces here is a picture of my layer manager Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 OK. I am sorry Layer name nowadays accept space within . Anyway I tried it in mine and it does work also with space, like this : (sssetfirst nil(ssget "_x" '((0 . "TEXT,MTEXT")(8 . "Layer 1")))) So copy it, and change Layer name only . Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 doesnt work either ... this was my input: (sssetfirst nil(ssget "_x" '((0 . "TEXT,MTEXT")(8 . "Layer 4")))) this was in command line: (sssetfirst nil(ssget "_x" '((0 . "TEXT,MTEXT")(8 . "Layer 4")))) (nil nil) Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 It is nil , Because you do not have texts under the Layer name. Get sure first, and retry once again. Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 i have 23 texts in that layer Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 doesnt work either ... this was my input: (sssetfirst nil(ssget "_x" '((0 . "TEXT,MTEXT")(8 . "Layer 4")))) this was in command line: (sssetfirst nil(ssget "_x" '((0 . "TEXT,MTEXT")(8 . "Layer 4")))) (nil nil) You wrote the name of the Layer wrong (Layer 4) it should be (Level 4) Right ?:wink: Regards, Quote
Acad_2010_user_NL Posted August 19, 2010 Author Posted August 19, 2010 Do'h i was stupid haha thanx!!! that was the problem haha now it works perfectly thx Quote
Tharwat Posted August 19, 2010 Posted August 19, 2010 I am so glad for you . good luck and have a nice day. Regards, Tharwat Quote
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.