acad dxtables tutorials

24
C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modified: 3/1/07 Usage Scenario | 1 Working with Tables in AutoCAD Creating a Cost Estimate Table in AutoCAD This tutorial outlines the procedures involved in creating a cost estimate table in AutoCAD by linking cost data maintained in a Microsoft Excel spreadsheet with properties extracted from an AutoCAD drawing. Audience: AutoCAD users new to AutoCAD 2008 table enhancements Prerequisites: Working knowledge of AutoCAD tables Time to complete: 30 minutes Usage Scenario John Cad and Partners have entered into an agreement with Nashua High School to design the layout of the school campus in New Hampshire. Problem: John Cad and Partners have to provide a cost estimate report for the new piping system included in the school plan. Using the layers in the

Upload: kathir

Post on 22-Apr-2015

23 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Acad Dxtables Tutorials

Working with Tables in AutoCAD

Creating a Cost Estimate Table in AutoCAD

This tutorial outlines the procedures involved in creating a cost estimate table in AutoCAD by linking cost data maintained in a Microsoft Excel spreadsheet with properties extracted from an AutoCAD drawing.

Audience: AutoCAD users new to AutoCAD 2008 table enhancements

Prerequisites: Working knowledge of AutoCAD tables

Time to complete: 30 minutes

Usage Scenario

John Cad and Partners have entered into an agreement with Nashua High School to design the layout of the school campus in New Hampshire.

Problem: John Cad and Partners have to provide a cost estimate report for the new piping system included in the school plan. Using the layers in the

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Usage Scenario | 1

Page 2: Acad Dxtables Tutorials

AutoCAD drawing, the firm wants to dynamically extract the pipe lengths for different utilities (stored in AutoCAD), and combine it with cost data (main-tained in a Microsoft Excel spreadsheet). The table then needs to be format-ted based on company-specific standards.

Solution: John Cad and Partners can use the following functionalities in AutoCAD to solve their problem:

1 Create a link to the cost data maintained in a Microsoft Excel spreadsheet

2 Associate the cost data with the pipe lengths extracted from the AutoCAD drawing

3 Create a new table cell style in AutoCAD and apply it to the table

Features Covered in This Tutorial

1 Data Extraction

2 Data Linking

3 Table enhancements

Tutorial Files

All the necessary files for this tutorial can be found in http://www.autodesk.com/autocad-tutorials.

Recommended: Before starting the tutorials:

1 Download the table_dataextraction_tutorial.zip file from http://www.autodesk.com/autocad-tutorials.

2 Unzip table_dataextraction_tutorial.zip to C:\My Documents\tutorials.

In This Tutorial

■ Lesson 1: Creating a Link to Data in a Spreadsheet■ Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

2 | Chapter Working with Tables in AutoCAD

Page 3: Acad Dxtables Tutorials

Lesson 1: Creating a Link to Data in a Spreadsheet

Creating a link to data stored in a spreadsheet

In this lesson, you will help John Cad and Partners create a dynamic link to data maintained in the cost_estimates.xls spreadsheet.

File Name: cost_estimate.xls and civilplan.dwg

Commands used: DATALINK

Concept: Data Link creates a dynamic link to information maintained in a Microsoft Excel spreadsheet.

Create a link to cost estimate data stored in a spreadsheet

1 Click Start menu (Windows) > Programs > Autodesk > AutoCAD 2008 > AutoCAD 2008.

2 Click File > Open.

3 Navigate to C:\My Documents\tutorials, and click civilplan.dwg. Click Open.

4 Click Tools menu > Data Links > Data Link Manager.

Alternatively, enter DATALINK in the command line window.

The Data Link Manager appears.

5 Under Excel Links, click Create a new Excel Data Link.

6 In the Enter Data Link Name dialog box, enter cost_data. Click OK.

The New Excel Data Link dialog box appears.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 1: Creating a Link to Data in a Spreadsheet | 3

Page 4: Acad Dxtables Tutorials

7 Click the Browse button.

8 Navigate to C:\My Documents\tutorials\cost_estimate.xls. Click Open.

9 Ensure that the Link Entire Sheet option is selected. Click OK.

10 Verify that cost_data is selected in the Data Link Manager window. Click OK.

11 Click File menu > Save. You have created and saved a dynamic link to the cost estimates spreadsheet.

NOTE To verify the link, invoke Data Link Manager by clicking Tools menu > Data Links > Data Link Manager. The Excel link — cost_data — should be listed in the Links pane. Click OK to close the dialog box.

Congratulations! You have helped John Cad and Partners create a dynamic link to data in the cost estimates spreadsheet.

Summary: In this lesson, you used the Data Link manager to create a dynamic link to a Microsoft Excel spreadsheet.

Next Lesson: Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

4 | Chapter Working with Tables in AutoCAD

Page 5: Acad Dxtables Tutorials

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD

In this lesson, you will help John Cad and Partners accomplish the following:

■ Create a cost estimate table after:

Extracting the piping systems data in the civillines.dwg file

Creating a relationship between data extracted from a) the civil lines drawing containing the piping systems information and b) the cost_estimates.xls spreadsheet

■ Create and apply company-specific standards to the cost estimate table■ Use AutoFill to automatically populate a column

Commands used: DATAEXTRACTION / DX

File Name: civilplan.dwg, civillines.dwg, and cost_estimate.xls

Concept: Data Extraction provides a tabular report of information extracted from an AutoCAD drawing and a Microsoft Excel spreadsheet.

Create a cost estimate table using the data extraction wizard

1 Ensure that you have civilplan.dwg file open in the work area.

2 Click Tools menu > Data Extraction.

Alternatively, enter DX or DATAEXTRACTION in the command line

The Data Extraction wizard appears.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 5

Page 6: Acad Dxtables Tutorials

3 In the Begin (Page 1 of 8) page, ensure that the Create a new data extrac-tion option is selected. Click Next.

4 In the Save Data Extraction As dialog box, navigate to C:\My Docu-ments\tutorials.

5 Enter cost_est as the file name. Click Save.

The default extension of the Data Extraction file is .dxe.

6 In the Define Data Source (Page 2 of 8) page, clear the Include current drawing check box.

7 Click the Add Drawings button.

You will add civillines.dwg (a dwg reference file) as the current drawing. civ-illines.dwg contains the piping systems information.

8 In the Select Files dialog box, navigate to C:\My Documents\tutorials, and click civillines.dwg. Click Open.

The path to the selected drawing should appear under the Drawing files and folders pane.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

6 | Chapter Working with Tables in AutoCAD

Page 7: Acad Dxtables Tutorials

9 Click Next. The Loading Files dialog box appears briefly.

NOTE The duration of the extraction process depends on the number of objects being extracted.

The Select Objects (Page 3 of 8) page appears.

10 Right-click any row in the Objects pane. Click Uncheck All to clear the check boxes.

11 Select the Arc, Line, and Polyline check boxes. These objects represent the piping systems in the civillines.dwg file.

You will rename the display names for Arc, Line, and Polyline to Pipes.

NOTE The Data Extraction wizard uses the display names to reconcile the records (rows) when you combine record modes.

12 Click Arc under the Display Name pane to select the row.

13 Click once inside the cell, and enter Pipes as the Display Name.

NOTE The Data Extraction wizard is case-sensitive.

You can also change the display name by typing the entry directly in the cell.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 7

Page 8: Acad Dxtables Tutorials

14 Enter Pipes as the Display Name for the Line and Polyline objects. Click Next.

The Select Properties (Page 4 of 8) page appears.

15 Right-click in the Properties pane. Click Uncheck All to clear the check boxes.

NOTE If you do not see any values in the Properties pane, verify that the check boxes in the Category Filter pane are selected.

16 Scroll down; and select the Layer and Length check boxes. Click Next.

The Non-Uniformly Scaled Blocks dialog box appears.

Objects in blocks that were not scaled uniformly cannot be extracted because the numerical values may not be correct or useful.

Refer to the concept of Non-Uniformly Scaled Blocks in the online help for more information.

17 Click OK to close the Non-Uniformly Scaled Blocks message box.

The Refine Data (Page 5 of 8) page appears.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

8 | Chapter Working with Tables in AutoCAD

Page 9: Acad Dxtables Tutorials

18 In the Refine Data (Page 5 of 8) page, make or verify that the following changes are included:

Select (if cleared) Combine identical rows check box

Clear Show count column check box

Select (if cleared) Show name column check box

19 Click the Link External Data button.

The Link External Data dialog box appears.

20 Select cost_data in the Data link drop-down list.

NOTE If you do not see cost_data in the drop down list, exit the wizard (click Cancel), and complete steps 4 through 11 outlined in Create a data link.

21 In the Data Matching pane, make the following selections from the drop-down list:

Drawing data column: Layer

External data column: Piping Systems

The Layer and Piping Systems are the match column.

22 Click the Check Match button.

23 Ensure the Valid Key message box displays. Click OK.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 9

Page 10: Acad Dxtables Tutorials

The data matching validation process succeeds as it finds a valid match between the Layer (drawing data) and Piping Systems (spreadsheet) col-umns.

NOTE If you see the Check Key message box, verify that you have selected the Layer and Piping Systems columns.

24 Under the Additional columns for data table pane, clear the Piping Sys-tems check box.

25 Click OK to return to the Refine Data (Page 5 of 8) page.

The inserted columns contain a link icon denoting they are linked.

26 Right-click the Cost column. Click Insert Formula Column in the shortcut menu.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

10 | Chapter Working with Tables in AutoCAD

Page 11: Acad Dxtables Tutorials

27 Enter Sum as the Column name. Create the formula: Cost * Length by double-clicking the Column Name in the Columns pane.

NOTE If you type in the formula, you must ensure that a) the Column names are enclosed within angle brackets, for example, <Cost>; and b) Column Name case, and Formula value case match.

28 Click Validate to ensure that the formula is valid. The Valid Equation mes-sage box should display. Click OK.

NOTE If the Invalid Equation message box displays, verify that the column names are correctly included. Alternately, click Cancel, and repeat steps 1 through 30 in this section.

29 Click OK to return to the Refine Data (Page 5 of 8) page.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 11

Page 12: Acad Dxtables Tutorials

The Sum column now displays the icon denoting a formula column.

30 Right-click in the Length column. Click Combine Record Mode menu > Sum Values.

This action groups similar layer values based on the Display Name, and lists the sum of the columns selected.

NOTE If you do not see the same values in the Sum column, ensure that a) you have entered Pipes in sentence case as the value in all 3 rows or b) you have selected the Combine Record Mode menu only in the Length column.

31 Right-click the Sum column. Click Insert Totals Footer menu > Sum. Click Next.

32 In the Choose Output (Page 6 of 8) page, select the Insert data extraction table into drawing check box. Click Next.

The Table Style (Page 7 of 8) page appears.

Create and apply company-specific standards using table cell styles

1 Ensure that you are in the Table Style (Page 7 of 8) page of the Data Extrac-tion wizard.

NOTE If you are not in Table Style (Page 7 of 8) page, repeat steps 1 through 32.

2 In the Table Style pane, click the Table Style icon .

3 In the Table Style dialog box, click New.

4 Enter cost_style as the new style name, and select Standard in the Start With drop-down list. Click Continue.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

12 | Chapter Working with Tables in AutoCAD

Page 13: Acad Dxtables Tutorials

The New Table Style dialog box appears.

5 In the Cell Styles pane, select Create new cell style from the drop-down list.

TIP You can also click the Create a new cell style icon .

6 Enter cost_data as the new data cell style name, and select Data in the Start With drop-down list. Click Continue.

7 Change the following values listed in the General tab:

Property Value

Fill Color Blue

Alignment Top Left

Format Currency*

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 13

Page 14: Acad Dxtables Tutorials

*Click the Browse button to update the Format value.

8 Click the Text tab.

9 In the Text color drop-down list, click Select Color.

The Select Color dialog box appears.

10 In the Index Color tab, enter 255 (white) in the Color text box. Click OK.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

14 | Chapter Working with Tables in AutoCAD

Page 15: Acad Dxtables Tutorials

You will now create cost_header and cost_title in a similar manner.

11 Create a new header cell style labeled cost_header, and select Header in the Start With drop-down list. Click Continue.

12 Make the following selections in the Borders tab:

13 Create a new title cell style labeled cost_title, and select Title in the Start With drop-down list. Click Continue.

14 Make the following selections in the Text tab:

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 15

Page 16: Acad Dxtables Tutorials

15 Click OK.

16 Verify that cost_style is selected as the current Table Style. Click Close.

17 Verify that cost_style is selected as the Table style.

18 Under the Formatting and structure pane, make the following changes and selections:

Label / Property Value

Enter a title for your table Cost Estimate

Title cell style cost_title

Header cell style cost_header

Data cell style cost_data

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

16 | Chapter Working with Tables in AutoCAD

Page 17: Acad Dxtables Tutorials

19 Click Next. Click Finish.

20 Move the cursor to the right-hand corner of the drawing.

21 Click once in the work area to insert the table.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 17

Page 18: Acad Dxtables Tutorials

If you do not see the cursor, do the following:

Restart the wizard.

Select Use previous extraction wizard as a template check box.

Click the Browse button.

Navigate to C:\My Documents\tutorials\cost_est.dxe. Click Open.

NOTE You will have to reinsert the totals footer (Insert Totals Footer menu > Sum).

22 Click File menu > Save to store the changes you have made.

Use AutoFill to automatically populate the serial number column

1 Ensure that you are in the main AutoCAD work area, and have inserted the table as described in the preceding section.

2 Zoom in (View menu > Zoom > In) till you can see the contents of the table.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

18 | Chapter Working with Tables in AutoCAD

Page 19: Acad Dxtables Tutorials

3 Click inside the table to select it and to display the just-in-time (JIT) Table toolbar.

NOTE If you see the table covered with tiny grids , click a cell in the table to clear the grid.

4 Click column A (top left column).

5 Click the Insert Column to Left icon on the Table toolbar.

6 Click the newly inserted column cell header (column A) to select the entire column.

7 Right-click any of the square grips in column A. Click Locking menu > Unlocked.

This action ensures the column’s contents and format can be modified.

8 Click to select header cell A2.

9 Right-click the header cell A2. Click Cell Style menu > cost_header.

10 Enter Item Number as the header. Click OK in the Text Formatting toolbar.

11 Click header cell A2 again.

12 Click the right grip in the cell and drag it to the right to increase the cell width.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 19

Page 20: Acad Dxtables Tutorials

13 Click data cell A3, and enter 1 as the first value. Click OK in the Text For-matting toolbar.

NOTE The value of data cell A1 will be displayed as $1.00. You will change the data format to Decimal Number to use AutoFill.

14 Click data cell A3 to select it.

15 SHIFT-SELECT data cell A7 to select cells A3-A7.

16 Right-click the selected column. Select Data Format from the shortcut menu.

The Table Cell Format dialog box appears.

17 Make the following selections, and click OK.

Data Type: Decimal Number

Format: Decimal

Precision: 0

18 Click data cell A3 to select it.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

20 | Chapter Working with Tables in AutoCAD

Page 21: Acad Dxtables Tutorials

19 Move your mouse to the bottom- right corner of the selected cell (A3), and place your cursor in the exact center of the grip.

20 Click the grip.

21 Right-click the AutoFill grip. Select Fill Series in the shortcut menu.

22 Drag the AutoFill grip to cell A7 to increment the value for each cell by 1.

The Serial Number column should now be populated with the series.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 21

Page 22: Acad Dxtables Tutorials

Summary: In this lesson, you learned to do the following:

■ Extract data from an AutoCAD drawings and combine it with a Microsoft Excel spreadsheet

■ Create a table cell style and apply them.■ Populate a column using AutoFill.

Congratulations! You have helped John Cad and Partners create a tabular report from data collated from AutoCAD and Excel. You have also helped the firm apply company-specific standards using table cell styles.

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

22 | Chapter Working with Tables in AutoCAD

Page 23: Acad Dxtables Tutorials

To learn more about data extraction, data linking, and data matching, refer to AutoCAD help for more information.

See Also

For more information on Data Extraction

Overview of Data Extraction

For more information on Data Linking and Matching

Understand Data Linking and Matching

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xmlLast modified: 3/1/07

Lesson 2: Creating a Formatted Cost Estimate Table in AutoCAD | 23

Page 24: Acad Dxtables Tutorials

C:\My Documents\My XML Files\PTDCPM\Spago-Tutorials\English\tut_01.xml Last modi-

24 | Chapter Working with Tables in AutoCAD