3D AutoCAD 2004/2005: One Step at a Time

 < Day Day Up > 


AutoCAD provides a pair of nifty tools with which you can edit attributes - the Block Attribute Manager (BAttMan) for editing attribute definitions after the block has been made, as well as the Enhanced Attribute Editor (EAttEdit) for editing attribute values. You'll more likely need to edit values than definitions. However, you might occasionally run into situations in which a definition needs some adjusting.

19.3.1 Editing Attribute Values

Figure 19.3.1a

Editing attribute values can be as easy as recalling the Edit Attributes dialog box we used in Exercise 19.2.2. We do this by using the older DDAtte command. The name of the dialog box changes from Enter Attribute to Edit Attribute, but otherwise, it's the same.

AutoCAD does provide a newer, more functional tool, however, that might better serve your needs. With the Enhanced Attribute Editor (Figure 19.3.1a), reached via the EAttEdit command, you can modify the value for each of the attributes of a selected block just as you could with the DDAtte command. Simply select the attribute with the value you wish to modify in the list box and then enter the new value in the Value box.

Figure 19.3.1a

Additionally, the Enhanced Attribute Editor allows you to modify text characteristics as shown in Figure 19.3.1b, and even some attribute properties as shown in Figure 19.3.1c. These improvements over the older DDAtte command justify AutoCAD's efforts toward the new and improved version!

Figure 19.3.1b

Figure 19.3.1c

Changes made via the Enhanced Attribute Editor affect only the value or properties/text options of the selected attribute. In the situation in which multiple instances of the same block occur (as with multiple gate valves in the next exercise), only attributes in the selected block will be modified. (This is also true when using the DDAtte command.) This will become clearer after the exercise.

Note 

You can also access the EAttEdit command from the Modify pull-down menu. Follow this path:

         Modify - Object - Attribute - Single…

Do This: 19.3.1.1 Editing Attribute Values

  1. Be sure you're still in the pid-19.dwg file the C:\Steps\Lesson19 folder.

  2. Follow these steps.

    TOOLS

    COMMAND SEQUENCE

    STEPS

    Command: v

    1. If the Cont_Station1 isn't current, restore it now.

    No Button Available

    Command: ate

    2. When we inserted the gate valves, we assigned a price value of 55.00. According to our chart at the end of our last exercise, the price should be 85.00.

    Enter the DDAtte command by typing ddatte or ate at the command prompt.

    3. Select anywhere on the left gate valve. AutoCAD presents the Edit Attributes dialog box. Change the 55.00 entry to 85.00 as shown.

    Pick the OK button to complete the command.

    Edit Attribute Button

    Command: eattedit

    4. That was quick and easy; let's try the EAttEdit method.

    Enter the command at the command prompt or pick the Edit Attribute button on the Modify II toolbar.

     

    Select a block:

    5. AutoCAD asks you to select a block. Select the other gate valve. AutoCAD presents the Enhanced Attribute Editor.

    6. Select the PRICE attribute and enter a value of 85.00 as shown.

    7. Now select the RATING attribute.

    8. Let's experiment a bit while we're here. Pick the Text Options tab and change the text style to Standard.

    9. Now change the layer to Info on the Properties tab.

     

    10. Pick the Apply and OK buttons to complete the procedure. Notice the difference in the 150# callout.

    Command: qsave

    11. Save the drawing but don't exit.

It's possible, using an older command line AutoCAD tool, to edit the values and some of the properties of attributes in multiple insertions of a block. The command sequence is:

Command: -attedit (or -ate)

Edit attributes one at a time? [Yes/No] <Y>:  [enter]

Enter block name specification <*>: [enter]

Enter attribute tag specification <*>: [enter]

Enter attribute value specification <*>:  [enter]

Select Attributes: [select the attributes to change]

Select Attributes: [enter to complete the selection set]

1 attributes selected. [AutoCAD reports how many attributes were selected]

Enter an option [Value/Position/Height/ Angle/Style/Layer/Color/Next] <N>: [tell AutoCAD what you want to do]

Note 

An easy way to see the values of all the attributes attached to a block is to set the Attdisp system variable to On. The command sequence looks like this:

     Command: attdisp

     Enter attribute visibility setting [Normal/ ON/OFF] <Normal>: on

It can be useful to display all the attributes when searching for errors, but the display can quickly become quite crowded.

  • The Normal option tells AutoCAD to display only those attributes created with the Invisible mode set to N.

  • Turning Off the Attdisp tells AutoCAD to hide all the attributes regardless of the Invisible mode settings. This setting will speed regeneration, but be careful not to place objects where they'll overlap the attributes when they're displayed again.

Let's try multiple attribute editing.

Do This: 19.3.1.2 Editing Attribute Values Globally

  1. Be sure you're still in the pid-19.dwg file the C:\Steps\Lesson19 folder.

  2. Be sure the Cont_Station1 view is still current.

  3. Follow these steps.

    TOOLS

    COMMAND SEQUENCE

    STEPS

    No Button Available

    Command: -ate

    1. Our project engineer has determined that this control station requires a higher rating for the block and bypass valves. Enter the -Attedit command by typing -attedit or -ate at the command prompt.

     

    Edit attributes one at a time? [Yes/No] <Y>: n

    Performing global editing of attribute values.

    2. We want to edit all the 150# valves. Tell AutoCAD that you don't want to Edit attributes one at a time.

    AutoCAD responds that this will be a global edit.

     

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

    3. We'll want only the valves on the screen to be affected by this editing.

     

    Enter block name specification <*>:  [enter]

    4. We'll be editing more than one type of block, so leave this default at the global setting.

     

    Enter attribute tag specification <*>: rating

    5. We want to edit only the Rating attributes. If we tell AutoCAD this, it won't change any other type of attribute.

     

    Enter attribute value specification <*>:  [enter]

    6. We don't need any further filtering for our edit.

     

    Select Attributes:

    Select Attributes: [enter]

    7. Select the three 150# attributes showing on the screen, and then confirm the selection.

     

    Enter string to change: 150#

    8. AutoCAD wants to know what to change …

     

    Enter new string: 300#

    9. … and what to make it.

    Your drawing looks like Figure 19.3.1.2.9a.

     

    Figure 19.3.1.2.9a

    Command: qsave

    10. Save the drawing but don't exit.

     

    Command: -ate

    11. Notice that the 3" attribute valve slightly overlaps the control valve stem. Let's move it over a bit. Repeat the -Attedit command.

     

    Edit attributes one at a time? [Yes/No] <Y>: [enter]

    Enter block name specification <*>: [enter]

    Enter attribute tag specification <*>: [enter]

    Enter attribute value specification <*>: [enter]

    12. This time, we can speed through the first four options by simply accepting the defaults.

     

    Select Attributes:

    Select Attributes: [enter]

    13. Select the 3" attribute value and then confirm the selection.

    1 attributes selected.

    Enter an option [Value/Position/Height/ Angle/Style/Layer/Color/Next] <N>: p

    14. AutoCAD reports the number of the selected attributes and then asks what you want to do. Tell it to edit the Position of the attribute.

     

    Specify new text insertion point <no change>:

    15. AutoCAD grabs the attribute at its insertion point and asks where you want to put it. Position it so that it doesn't touch the valve or the valve stem. (This may take a few tries to get it located properly.)

     

    Specify new text insertion point <no change>:1Enter an option [Value/Position/Height/ Angle/Style/Layer/Color/Next] <N>: [enter]

    16. Hit enter to conclude the command. The valve looks something like Figure 19.3.1.2.16a.

     

    Figure 19.3.1.2.16a

     

    Command: -ate

    17. Reposition the remaining attributes to clarify this area. The drawing will look like Figure 19.3.1.2.17a when you've finished.

     

    Figure 19.3.1.2.17a

    Command: qsave

    18. Save the drawing.

Let's take a look at how we can edit an attribute's definition after creating the block.

19.3.2 Editing Attribute Definitions

With the Block Attribute Manager (Figure 19.3.2a), AutoCAD has made editing attribute properties after block creation almost easier than editing them before you make the block! Access the manager with the BAttMan command, but exercise some caution when editing block properties. Remember that modifications may affect all insertions of the block (current and future).

Figure 19.3.2a

Let's take a look.

Let's see what BAttMan can do!

Do This: 19.3.2.1 Editing Attribute Definitions

  1. Open the pid-19-done.dwg file the C:\Steps\Lesson19 folder.

  2. Follow these steps.

    TOOLS

    COMMAND SEQUENCE

    STEPS

    Command: v

    1. Restore the I_O_LEFT view. Your drawing looks like Figure 19.3.2.1.1a.

    We'll work with the upper arrow-looking polygon. Notice that the text style differs from similar blocks. Notice also that there appears to be an extra attribute below the blocks. This type of situation might occur when you import a block from another drawing.

    We'll adjust this block to reflect styles and standards from our drawing.

     

    Figure 19.3.2.1.1a

    Block Attribute Manager Button

    Command: battman

    2. Open the Block Attribute Manager by entering battman at the command prompt. Alternately, you can pick the Block Attribute Manager button on the Modify II toolbar.

    Select Block Button

     

    3. On the Block Attribute Manager, pick the Select block button.

     

    Select a block:

    4. AutoCAD returns you to the graphics screen and prompts you to select a block. Select the upper block with the text that reads 100-CWR-D-1001.

    5. Select the TEXT attribute.

     

    6. Pick the Edit… button.

     

    7. AutoCAD presents the Edit Attribute dialog box (Figure 19.3.2b). Pick the Text Options tab.

    8. On the Text Options tab, change the Text Style to TIMES.

     

    9. Go to the Properties tab.

    10. Notice that the attribute was placed on the txt layer rather than the TEXT layer that is standard on this drawing. Change it to the proper layer. (If there is a check next to Auto Preview Changes, you can already see your changes.)

     

    11. Pick the OK button to return to the Block Attribute Manager.

     

    12. Now let's do something about that extra attribute. Select the Supplementary attribute in the list box and then pick the Edit… button.

    13. Just in case we need this attribute in the future, we'll put it on the proper layer. Repeat Step 10.

     

    14. Return to the Attribute tab.

    15. Rather than delete the extra attribute (there's always a chance we might need it later), we'll simply make it invisible. Place a check in the proper Mode box.

     

    16. Pick the OK button to return to the Block Attribute Manager.

     

    17. Pick the Apply button to apply your changes to all the insertions of the OFF- DRAWING-LEFT block.

     

    18. Pick the OK button to complete the procedure.

    Command: qsave

    19. Save the drawing.


 < Day Day Up > 

Категории