Author |
Topic |
|
mbicm
New Member
13 Posts |
Posted - August 15 2007 : 09:58:13 AM
|
ok i need some brainstorming. i got my attributed titleblock, and there is a field in there with the drawing number. the numbers are sequential throughout the whole set of drawings. they currently have a hyphen at the start so they look like -0610-001, -0610-002, etc. i am trying to get rid of the hyphen at the start of it all. at first i thought i could do a find and replace for -06 to 06 since these numbers remain the same through the whole project, but there is other -06's throughout the drawings that i dont want replaced. So the question is how do a remove the hyphen from 400 drawings? |
|
mbicm
New Member
13 Posts |
Posted - August 15 2007 : 10:26:17 AM
|
Or is there a way to do a find/replace only on the titleblock? |
|
|
n/a
deleted
112 Posts |
Posted - August 15 2007 : 12:13:13 PM
|
If the attribute has the same unique block name and tag, you should be able to construct a script using "-attedit", I think. If that is the case, if you can upload one of the DWG files, I can take a stab at it, although I might not get at it until this evening. |
Steve Bubendorf
|
|
|
mbicm
New Member
13 Posts |
Posted - August 15 2007 : 12:19:38 PM
|
our plants that we design are divided into areas. each area has a model and in that model is anywhere from 6 to 26 layout tabs. each tab is a different drawing number. with that said, attedit doesnt sound feasible. |
|
|
n/a
deleted
112 Posts |
Posted - August 15 2007 : 12:49:46 PM
|
The layouts definitely would make things more difficult. I think it still might be possible using Visual Lisp within a script. It might be a little too complex for me, but I'm still willing to give it a shot, if you are able to post a drawing so that I know what I'm working with. If posting the drawing is a problem due to confidentiality, I doubt if, given my meager abilities, I can get something to work. I expect it will take me a little trial and error. |
Steve Bubendorf
|
|
|
mbicm
New Member
13 Posts |
Posted - August 16 2007 : 5:32:37 PM
|
i found a lisp routine off the autodesk website at http://www.xanadu.cz/en/ called srxtext, which allows you to do find/replace in selected blocks or layers. when i scripted it i had to do a little more to get it to go through all the layout tabs. and i came up with
(foreach layout (layoutlist) (srxtext "Substring" "-06" "06" (setq ss1 (ssget "_X" '((0 . "INSERT") (2 . "titleblock"))))) ) |
|
|
|
Topic |
|