Author Topic: global attribute edit???  (Read 10556 times)

0 Members and 1 Guest are viewing this topic.

ELOQUINTET

  • Guest
global attribute edit???
« on: December 08, 2003, 01:42:21 PM »
hey guys i was just experimenting with the global attribute editor from express and quick select. i am wondering if there is a way to globally change attributes based on what the existing attribute is. for instance i have a set of drawings which need to be revised. the details are all called out but i have to rearrange the set. is there a way i can change all the section marks for 4/7 to be 7/8 without changing the other attributes that occur in the block to the same thing. how could i group the attributes together so that 4/7 would change to 7/8 but 5/7 would not be affected. i don't want to have to select each occurance. any suggestions?

dan

daron

  • Guest
global attribute edit???
« Reply #1 on: December 08, 2003, 03:20:38 PM »
find is a good example of that.

ELOQUINTET

  • Guest
global attribute edit???
« Reply #2 on: December 08, 2003, 03:59:09 PM »
yes i see what you can do with find. i'm just trying to figure out how i could have it find the two attributes for that given detail and change them globally from 2/7 to 5/7 without affecting any other occurances of 2,5 or 7 such as 2/5. does that make sense? my boss says we have to put 50 cent in a jar for every comment that shows up about ghost references so...

dan

Kate M

  • Guest
global attribute edit???
« Reply #3 on: December 08, 2003, 04:30:53 PM »
Just FIND "2/7" and REPLACE with "5/7"? I do it this way all the time. I don't know much about programming, but it doesn't sound like it'd be too hard to automate...

hyposmurf

  • Guest
global attribute edit???
« Reply #4 on: December 08, 2003, 04:48:46 PM »
You can also change the options in the "find" command to search for just block attribute values,rather than dimension text Mtext,Dtext & Text as well.

Trev

  • Guest
global attribute edit???
« Reply #5 on: December 08, 2003, 05:53:48 PM »
yep that could be done eloquintet
I wrote a VBA version of the global attribute edit a little while back. That maybe a good thing to add to the program.
So just to make sure I have got it correct.
an example being - a block named 'ABC' contains 2 attributes. This block could be on the dwg 20 times
but rather than change the value of each attribute you would like it to search for a value and only update the blocks that contain said old value.
So basically a search & replace function.
I think that could be arranged :)

daron

  • Guest
global attribute edit???
« Reply #6 on: December 08, 2003, 06:12:05 PM »
Also, don't forget in find you have a button that allows you to select which objects you want it to look at or change. Then all you have to do is hit replace all.

CADaver

  • Guest
global attribute edit???
« Reply #7 on: December 08, 2003, 09:59:15 PM »
-ATTEDIT N N <block name> <tag name> <value to find> <string to change> <new string>

Trev

  • Guest
global attribute edit???
« Reply #8 on: December 09, 2003, 02:53:31 AM »
Ah yes!
good idea Daron.
I added a search & replace capability to the gatte.dvb program today.
It still has the functionality of the orginal gatte.dvb
Although I have made it so it replaces all rather than loop through
a selection set.
But I could emulate the find and replace that is used in text editors etc. Including making it zoom to next item so you can see each item in turn, elect replace then it will zoom to next etc.
I think that would be better :)

Plus I could make it do what 42 had requested on an earlier post.
check for an integer value & if so make an addition to an existing value
ie: add '3' to each value so 1 becomes 4, 2 > 5 etc, etc.

daron

  • Guest
global attribute edit???
« Reply #9 on: December 09, 2003, 09:35:17 AM »
That will be one sweet routine. Gatte w/a form w/ find embedded within it.

ELOQUINTET

  • Guest
global attribute edit???
« Reply #10 on: December 09, 2003, 09:36:18 AM »
this is kinda what i'm looking for but let me clear a few things up. my block does not actually read as 2/5 or whatever. it's your typical detail block with a circle divided by a line with the detail number as an attribute on top and it's sheet location as an attribute on the bottom. i would like  to be able to globally edit the block containing these two attributes but leave the others alone. for instance if i change 2/5 to 2/6 i don't want 3/5 to change to 3/6. does that make better sense. i like some of the ideas being tossed around like the addition option.

dan

CADaver

  • Guest
global attribute edit???
« Reply #11 on: December 09, 2003, 01:16:42 PM »
Quote from: eloquintet
this is kinda what i'm looking for but let me clear a few things up. my block does not actually read as 2/5 or whatever. it's your typical detail block with a circle divided by a line with the detail number as an attribute on top and it's sheet location as an attribute on the bottom. i would like  to be able to globally edit the block containing these two attributes but leave the others alone. for instance if i change 2/5 to 2/6 i don't want 3/5 to change to 3/6. does that make better sense. i like some of the ideas being tossed around like the addition option.

dan


What is it you don't like about:

-ATTEDIT N N <block name> <tag name> <value to find> <string to change> <new string>

Or am I confused?

ELOQUINTET

  • Guest
global attribute edit???
« Reply #12 on: December 09, 2003, 02:10:19 PM »
not sure i understand what you're gettin at cadaver. when i type in what you say it just tells me to select block, doesn't give me those options. the toughest thing i'm thinking would be to find and change only the 2 attributes detail #2 on sheet 5 to detail#2 on sheet 6 and not change detail #3 on sheet 5 to detail#3 on sheet 6. does anyone know what the hell i'm talking about?

dan

daron

  • Guest
global attribute edit???
« Reply #13 on: December 09, 2003, 02:20:16 PM »
As long as you do, there'll always be someone who understands what you're talking about.

CADaver

  • Guest
global attribute edit???
« Reply #14 on: December 09, 2003, 05:20:12 PM »
Quote from: eloquintet
not sure i understand what you're gettin at cadaver. when i type in what you say it just tells me to select block, doesn't give me those options. the toughest thing i'm thinking would be to find and change only the 2 attributes detail #2 on sheet 5 to detail#2 on sheet 6 and not change detail #3 on sheet 5 to detail#3 on sheet 6. does anyone know what the hell i'm talking about?

dan


Works fine for me in R2002 and only changes the current layout, make sure you answer NO twice.  Then again, maybe I'm missing what you're askin'??

    Command: -attedit

    Edit attributes one at a time? [Yes/No] <Y>:
NO
Performing global editing of attribute values.

Edit only attributes visible on screen? [Yes/No] <Y>: NO


Drawing must be regenerated afterwards.
Enter block name specification <*>: [Yes/No] <Y>: Key-in block name


Enter attribute tag specification <*>:Key-in TAG name  <right here key-in the tag name you're looking to eidt>

Enter attribute value specification <*>: Key-in value looking for


13 attributes selected.
Enter string to change: 1
Enter new string: 2[/list:u]

For "Block name", Tag name", and "value specification", wildcards may be used.  DET* will only look at blocks whose name starts with "DET".

Be sure to use enough letters to properly define which attributes are selected.

~~~~~~~~~~~~~~~~~~~~~~

If you wish to select the attribute to change, answer yes to the second query and you'll be in a "select Attributes" loop where you can use Window or Crossing, etc.

Trev

  • Guest
global attribute edit???
« Reply #15 on: December 09, 2003, 06:32:44 PM »
eloquintet
I have made it do as your request.
provided I understad correctly. :)
ie: 10 blocks on dwg with an attribute value
a, b, c, d, e   2 blocks are identical.
search for block with attribute value 'c' change it to 'h' & leave all others as is.
I'll start adding the other suggestions of Daron's today.

ELOQUINTET

  • Guest
global attribute edit???
« Reply #16 on: December 10, 2003, 08:32:59 AM »
sounds like youmay be on the right path trev but let me ask you the question i keep bringing up. if i need to change the detail number and sheet number what happens to other occurances of the block which may have one or the other value. i'll give a complete example. i have a block called detail with two attributes detail number and sheet number. the detail number is 5 on sheet A3. ok i have to move the detail to 1 on A4. i edit the block. my question is what happens to the occurances such as 5 on A4 would that change to 1 on A4. and what about detail 4 on sheet A3 would that change to 4 on A4. maybe i'm rambling on about something that you've already figured out i don't know. thanks guys

dan

Trev

  • Guest
global attribute edit???
« Reply #17 on: December 10, 2003, 08:57:05 AM »
Yep thats the examples I have been testing on.
(I was using section arrows ie: Section A on dwg M1  very much the same)So I'm in the ball park.

What I am doing to over come that is using a find feature that will zoom to the block/attribute in question where you can select replace or go to next, this basically will loop through all the blocks in the selection set. In your case a block called 'detail' which you will have highlighted in a block list on the form or you have an option to select a block from the screen.
So as it loops from one block to the next you click 'replace' and that will update just the one item then go to next. (the same way you do a search and replace in any text editor) This might be a bit of a pain if you had heaps of blocks with the same value but only wish to replace a couple of them.
I also have a replace all option, which will replace all attribute values as your eg:A3 to A4
(I credit the above ideas to Daron)

I still have a little tidy up work on it, I have the forms all done. All I need to do now is just fix up the loop through each block to replace item one at a time.

I like this program if I do say so myself.   8)
I hope to post gatte.dvb version 2  (Global Attribute Edit)
tommorow night.

Trev

  • Guest
global attribute edit???
« Reply #18 on: December 16, 2003, 09:44:13 AM »
hmmm nearly there.
sorry for the delay.

ELOQUINTET

  • Guest
global attribute edit???
« Reply #19 on: December 16, 2003, 09:51:01 AM »
okie dokie take your time trev no big deal

dan

Trev

  • Guest
global attribute edit???
« Reply #20 on: December 23, 2003, 09:57:47 AM »