Importing excel data into attributes AutoCAD 2021

Importing excel data into attributes AutoCAD 2021

kwrightKDC7A
Explorer Explorer
2,947 Views
6 Replies
Message 1 of 7

Importing excel data into attributes AutoCAD 2021

kwrightKDC7A
Explorer
Explorer

Hello!

 

I am trying to create a link between an excel file and CAD file. I would like text data from excel to fill in predefined attributes once the excel data is imported.

 

I was working off of this SOP:

https://knowledge.autodesk.com/support/autocad/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to...

 

Here is what I have done:

  • Created text attributes where I need them and but them into one block. (ex. Project name, Project location...)
  • Exported attributes to a TXT file
  • Copied this data into an excel file
  • Linked the project specific data to the cells for the attribute Value
  • Go to import the attributes but it seems it will only allow .TXT files

I am trying to avoid converting the excel file back to a .TXT file, I want this to be something that can be done with as few clicks as possible so I can use it on all projects moving forward. The excel file will already be created for other needs so I am trying to streamline my work.

 

Thank you!

Kelsey

0 Likes
Accepted solutions (1)
2,948 Views
6 Replies
Replies (6)
Message 2 of 7

TheCADnoob
Mentor
Mentor

Change your excel file to a CSV file. 

CADnoob

EESignature

0 Likes
Message 3 of 7

kwrightKDC7A
Explorer
Explorer

@TheCADnoob thank you for the quick reply.

 

I did as you recommended but when I click import attributes and navigate to the file folder with the CSV file CAD is still looking for just .TXT files. If I drop down on the "files of type" it only lists .TXT

0 Likes
Message 4 of 7

leeminardi
Mentor
Mentor

You might find post #9 here helpful.

lee.minardi
0 Likes
Message 5 of 7

TheCADnoob
Mentor
Mentor
Accepted solution

sorry i forgot a few steps. 

 

When you have it saved as a csv you have to change the file extension to .txt. A csv file is in essence a text file. 

TheCADnoob_0-1657926862972.png

 

 

One you change the file extension open the text file and do a find and replace for commas (ctrl +H). 

(note if you have commas in you data you will have to work your way around those)

(note to do a replace for a tab got to the last spot in your text file and hit tab. Then select it and cut it)

TheCADnoob_5-1657927155905.png

 

 

Hit replace all

 

TheCADnoob_6-1657927178667.png

 

 

After replacing all you data will be ready to be read in

TheCADnoob_7-1657927196057.png

 

Remember to save after you made the change. 

 

 

 

 

CADnoob

EESignature

Message 6 of 7

kwrightKDC7A
Explorer
Explorer

Thank you so much for the detailed response! 

Message 7 of 7

TheCADnoob
Mentor
Mentor

Glad to help. Sorry i didn't give that response the first time. sometimes i have to step back and remember that things aren't always as obvious haha. Its a pretty convoluted process to get from changing from CSV to importing data lol

CADnoob

EESignature