BlkDatExp Block Export Data

ToolPac Export Data allows you to export Block and Attribute data to a comma separated ASCII file. This improves on the process of AutoCAD's Attribute Extraction process. It allows you to simply point and click to determine the fields to export, and does not require an external template file.

Keyboard Command: BlkDatExp

BlkDatExp

Notice that the dialog is separated into two sections. The left section contains Option Fields, which are potential fields for inclusion in the data export. The right section contains Output Fields, these are fields that have been chosen for exporting data. No field can exist on both sides. Any number of fields can be moved from one side to the other.

Procedure:

  1. Select the Block Attribute Export option from the Block submenu.
  2. Select blocks to process. This step will determine the blocks you want to export, as well as allows the routine to scan the selection set to determine what potential attribute fields are available based on the selection set.
  3. Select the fields to export in the order you wish them to appear in the file. This may involve a couple of operations if you are trying to achieve a certain order for the fields. Consider these points when selecting.
    • Data will be exported in the order shown in the Output Field section.
    • Choose desired fields from the Option Fields section, then choose the Add To List button to move the field to the right. Repeat for each group of fields you wish to move.
    • If you change your mind about fields in the Output Field section, you can move them back to the Option Fields lists with the Remove From List.
  4. Designate the Output File for exported data.
  5. Choose the OK button to process the selected data.

Output Column Headings will usually always be turned on. This allows you to tell what each column is as well as controlling the fields in target environments like spreadsheets, databases, etc. The ToolPac Block Data Import routine requires column headings.

Use Quotation Marks is optional. Turning this toggle on will cause each field to be enclosed in quotation marks. ToolPac's Data Import does not require quotation marks.

ToolPac's Import/Export tools are widely used to send attribute data to Excel, where fields are calculated and populated. This data then needs to be returned to the drawing.

Procedure:

  1. Use the Block Attribute Export option.
    • Include the .HANDLE and .BLOCKNAME fields first.
    • Include the desired attribute fields next in any order.
    • Use the file extension CSV when saving the file.
  2. Open (File Type = CSV) the file in Excel.
  3. Make all desired changes in Excel.
  4. From Excel, Choose File, then Save, choose Yes to overwrite.
  5. From Excel, Choose File, then Close, choose No to keep existing format.
  6. Use ToolPac's Block Import, then choose the CSV file.

Excel Notes:

Excel will open a file with the CSV extension without going into the wizard import. Always include all columns if you sort, so that handles do not get separated. The CSV file must be closed in Excel before ToolPac's Import can read it.