Skip links

Reader Interactions

Comments

  1. Hi Don,
    I have a question, how can I link autocad attributes into excel spreadsheet? I want something like, every time I made changes in my attributes, it will automatically update changes in my excel spreadsheet. I will appreciate everyones response. Thanks

  2. I want to make bloks with attributes, and then to export that attributes to excel. I know how to do that. Now I would like to link that cells in excel with my attributes. In that way, when I change something in my excel table and do relaod in dwg I can see changes and also, when I change some atribute in dwg I want to see changes in excel db. Do you have some hint?
    Thanks.
    Milan

  3. I have block with visibility parameter. When use ATTOUT command, it’s doesn’t export visibility parameter. I want to export this parameter to to edit it, after that import to AutoCAD to control visibility of block. Do you have any solution to solved my problem.
    Sorry about duplicate information.Thanks

  4. como puedo pasar una planilla excel a autocad y luego cambiar cosas en la planilla como por ejemplo el layer del texto

  5. Ok. Thanks for the quick reply. Have looked at another way to solve it. I tried to link into a range from excel with copy and paste method. I will then have to update data in AutoCAD from Excel. And it works! But when I try to update from AutoCad LT 2012 to excel by using the “Update to source” button I get a message;
    Command: _DATALINKUPDATE
    Select an option [Update data link/Write data link] : _W
    1 object(s) found.
    1 data link(s) do not allow their data to be written out.
    0 data link(s) written out successfully.
    How can I fix this?

  6. Hello. I have a number of different signs (blocks) in AutoCad. I want to count the number of each unique signs and export it to excel? So that I excel can see how many signs I have of each type.
    User AutoCad LT 2012How can I do it? (im a autocad newbie)

  7. A couple of points I would add to this blog post is that when you import the text into Excel make sure you set all the columns as text-format so you don’t get things like “1/2” turning into dates and other assorted Excel formatting weirdness. You can also re-order and delete columns – except for the Handle and Block Name columns, leave them alone. You can sort the rows in any order as long as you keep the heading row at the top. Don’t leave any gaps between columns and rows. Insertion order determines the order of the block Handles. A tip if you’re using arrays to make collections of blocks – make one extra and delete the original one you cloned; the Handles tend to flow in a neater order.

    I use a modified version of the attout.lsp included with AutoCAD which opens the export in Excel automatically but I can’t distribute that because it is copyrighted code. I am, however, working on a custom version of this which would automate a lot of things and allow for more sorting options. If you’re interested in this then I may enlist you as a beta-tester. I estimate about 6 months or so until I have something worth testing. Keep an eye on CADbloke.com &/or send me a message on my contact page if you’re interested.

    cheers
    Ewen
    CADbloke

  8. dear Donnie,

    My blocks are explicit declared.
    My question: Wiht ATTOUT.lsp Is that possible to update the blocks via attin without HANDLE but only with BLOCKNAME?
    …… (setq str (strcat “HANDLE” delim “BLOCKNAME”));setq

    thank you alot for this webpage

  9. That is a very good article about block attribute. I have made a tutorial about how to create the block attribute first. feel free to read it also. Thanks!

  10. Richard – I am not aware of an efficient way to do this using Excel and Block Attributes. Before Sheet Set Manager was introduced to AutoCAD this is the way I recommended to people who wanted an easier way to manage their drawing sheets. On the other hand, now that we have Sheet Set Manager I highly recommend it over the method outlined in this post. If you want to use Sheet Set Manager, but not loose the flexibility of having each sheet field as an attribute; try defining your block attributes with a Sheet Set Manager field as the attributes default value. That way you get the best of both worlds. Likewise SSM is also able to create a Sheet List Table (which can be customized to display any SSM field). Also, since it is a table you do have the option of exporting it to an external file that you could then use in Excel if needed.

  11. While I understand the desire to learn how to code and work in AutoCAD, if you are like me and don’t have time to learn all the details of how CAD works, you find a program that will do it for you.

    http://www.xanadu.cz/en/excellink.asp

    Excellink may have been mentioned in a previous post, but I found it did EXACTLY what I needed. You can’t use excel to create NEW blocks, but you can use it to change any and all attributes and properties of a dynamic block (except for the handle that AutoCAD assigns each block when the block is created).

    Excellink allows you to work actively between the two programs; updating block attributes as changes are made in Excel.

    • While I have never personally used ExcelLink, I have known users who have. Thus about all I can say is that I have never heard much if any negative feedbackabout the product. Judging from your feedback, a core advantage to ExcelLink over this method is the dynamic link between Excel and AutoCAD. This method is in fact rather static, but to it’s credit it’s free, and most likely already installed on your machine (assuming you have Express Tools instaled).

      • Here's what i want to have, a drawing list from excel sheet is link to the the attributes in the title block. That if i change from excel it also automatically changes in the drawings or vice versa…can this be done in express tools?…or in plain autocad without using excellink?

  12. While I understand the desire to learn how to code and work in AutoCAD, if you are like me and don’t have time to learn all the details of how CAD works, you find a program that will do it for you.

    http://www.xanadu.cz/en/excellink.asp

    Excellink may have been mentioned in a previous post, but I found it did EXACTLY what I needed. You can’t use excel to create NEW blocks, but you can use it to change any and all attributes and properties of a dynamic block (except for the handle that AutoCAD assigns each block when the block is created).

    Excellink allows you to work actively between the two programs; updating block attributes as changes are made in Excel.

    • While I have never personally used ExcelLink, I have known users who have. Thus about all I can say is that I have never heard much if any negative feedbackabout the product. Judging from your feedback, a core advantage to ExcelLink over this method is the dynamic link between Excel and AutoCAD. This method is in fact rather static, but to it’s credit it’s free, and most likely already installed on your machine (assuming you have Express Tools instaled).

      • Here's what i want to have, a drawing list from excel sheet is link to the the attributes in the title block. That if i change from excel it also automatically changes in the drawings or vice versa…can this be done in express tools?…or in plain autocad without using excellink?

  13. Hi
    I find updating the attributes from Excel very helpful.
    I am using Excel of OfficeXP.
    I came up with two problems, that I would like to know if there is awaqy to over come:
    1. Whenever the attribute contains a quotaion mark (like “X for X inches) I get the attribute in the drawing between quotaion marks.
    2. When I open the txt file in excel, the leading zeros of a number are removed. This is annoying as I have to add them by formatting the cells to text and adding the zeros. When opening next time it repeats itself

    Many thanks for this Blog
    Jacob Eilon

  14. Hi
    I find updating the attributes from Excel very helpful.
    I am using Excel of OfficeXP.
    I came up with two problems, that I would like to know if there is awaqy to over come:
    1. Whenever the attribute contains a quotaion mark (like “X for X inches) I get the attribute in the drawing between quotaion marks.
    2. When I open the txt file in excel, the leading zeros of a number are removed. This is annoying as I have to add them by formatting the cells to text and adding the zeros. When opening next time it repeats itself

    Many thanks for this Blog
    Jacob Eilon

  15. Is it possible to map the XYZ coordinates of an object through Excel? I have a set of data points entered in excel and I want to create a series of objects with one Excel column identifying their X-coordinate, one column identifying their Y-coordinate and, one column defining some text written next to the coordinate.

  16. Is it possible to map the XYZ coordinates of an object through Excel? I have a set of data points entered in excel and I want to create a series of objects with one Excel column identifying their X-coordinate, one column identifying their Y-coordinate and, one column defining some text written next to the coordinate.

  17. I am trying to change the text style on a couple items in our title block. I can’t figure out where that is done in a script because the Attribute Editor keeps opening up. Can you help.

    Thanks

  18. I am trying to change the text style on a couple items in our title block. I can’t figure out where that is done in a script because the Attribute Editor keeps opening up. Can you help.

    Thanks

  19. The information regarding block attribute modifications using excel and importing back into ACAD was a big help. I’ve been trying to figure it out for a day, then came across your instructions and was able to make the changes in less than 10 minutes.

    Thanks!!

  20. The information regarding block attribute modifications using excel and importing back into ACAD was a big help. I’ve been trying to figure it out for a day, then came across your instructions and was able to make the changes in less than 10 minutes.

    Thanks!!

  21. By the way it would also be cool to have an info box popping out upon a click on the object. A 15 fields info box perhaps, well I guess if it is possible at all then we should be able to customize the number of fields etc. easily, can’t we?

  22. By the way it would also be cool to have an info box popping out upon a click on the object. A 15 fields info box perhaps, well I guess if it is possible at all then we should be able to customize the number of fields etc. easily, can’t we?

  23. Dear Don,
    I am a civil engineer, and we are dealing with 7000 concrete cast in place piles which means a lot of effort to consolidate all information neatly on spreadsheets moreover the sequential numbers for each phase are likely to get confused in a spreadsheet of about 30×7000.
    I had an idea to map each pile on dwg (or on a loseless eps export of it) via an excel sheet, though I am not even slightly competent in data handling in Autocad, is it possible to automate some actions, perhaps something like changing fill color of the object( a pile ) automatically upon completion?

    Best,
    murad

    (Really user friendly blog)

  24. Dear Don,
    I am a civil engineer, and we are dealing with 7000 concrete cast in place piles which means a lot of effort to consolidate all information neatly on spreadsheets moreover the sequential numbers for each phase are likely to get confused in a spreadsheet of about 30×7000.
    I had an idea to map each pile on dwg (or on a loseless eps export of it) via an excel sheet, though I am not even slightly competent in data handling in Autocad, is it possible to automate some actions, perhaps something like changing fill color of the object( a pile ) automatically upon completion?

    Best,
    murad

    (Really user friendly blog)

  25. Hi,

    Realised why it wouldn’t let me select any blocks. Figured out that the blocks didn’t actually contain any attributes.

    Thanks for a great website!

  26. Hi,

    Realised why it wouldn’t let me select any blocks. Figured out that the blocks didn’t actually contain any attributes.

    Thanks for a great website!

  27. Hey,

    Do you know if there’s a way to link Excel to AutoCAD dxf blocks? For example, if you have let’s say a table in Excel which tabulates different parts of a car with coordinations and dimensions, can those data be transferred over into AutoCAD and translated automatically into different blocks, or am I thinking too futuristically?

    Appreciate a response.

  28. Hey,

    Do you know if there’s a way to link Excel to AutoCAD dxf blocks? For example, if you have let’s say a table in Excel which tabulates different parts of a car with coordinations and dimensions, can those data be transferred over into AutoCAD and translated automatically into different blocks, or am I thinking too futuristically?

    Appreciate a response.

  29. Hi,
    I’m a complete newbie to AutoCad so please excuse my ignorance.
    I am trying to follow the process outlined in the article to extract attribute information.
    I go to Express > Blocks > Export Attribute Information. And it asks where i would like to save the text file. I accept the default name and click on OK. The app then asks me to select the objects. I click once just outside the upper left corner of the object, and then the app asks me to select the opposite corner. I do so, but then it reverts back to “select objects”. Long story short, I can’t seem to select anything. Am i missing something?

  30. Hi,
    I’m a complete newbie to AutoCad so please excuse my ignorance.
    I am trying to follow the process outlined in the article to extract attribute information.
    I go to Express > Blocks > Export Attribute Information. And it asks where i would like to save the text file. I accept the default name and click on OK. The app then asks me to select the objects. I click once just outside the upper left corner of the object, and then the app asks me to select the opposite corner. I do so, but then it reverts back to “select objects”. Long story short, I can’t seem to select anything. Am i missing something?

  31. Donnie, check out Excellink by http://www.Zanadu.cz It’s a Chech company. I have been working with this program for about 6 years. Not only can it update block attributes, it can use Excel to modify location, rotation, layer, color, scale, etc. You need to check it out. Like you, I had problems with alignments changing. However, my alignments did not change as much as transmission line structure relocations & stations for those structures.

  32. Donnie, check out Excellink by http://www.Zanadu.cz It’s a Chech company. I have been working with this program for about 6 years. Not only can it update block attributes, it can use Excel to modify location, rotation, layer, color, scale, etc. You need to check it out. Like you, I had problems with alignments changing. However, my alignments did not change as much as transmission line structure relocations & stations for those structures.

  33. Hi, I used the express tools>export atrribute informatiion whcih I assume is the same thing. However what I need to do is sort my block by attribute in excel and then for prticular block I want to move them onto specifc layers. In simple terms I would expect to be able to quote the nadle name and then some command to assign to a specific layer. Any ides would be welcome.

  34. Hi, I used the express tools>export atrribute informatiion whcih I assume is the same thing. However what I need to do is sort my block by attribute in excel and then for prticular block I want to move them onto specifc layers. In simple terms I would expect to be able to quote the nadle name and then some command to assign to a specific layer. Any ides would be welcome.

  35. @Aurélie – It’s important to note that ATTIN/ATTOUT are Express Tools. It’s been a while since I worked with our 2008 deployments, but I’m pretty certain Express Tools is one of the optional things you can install.

    You may need to re-run your install (or modify your deployment to include the Express Tools).

  36. @Aurélie – It’s important to note that ATTIN/ATTOUT are Express Tools. It’s been a while since I worked with our 2008 deployments, but I’m pretty certain Express Tools is one of the optional things you can install.

    You may need to re-run your install (or modify your deployment to include the Express Tools).

  37. Hi everybody!

    I have a problem with these ATTIN and ATTOUT.
    that’s working in ACAD 2007, and it’s wonderful :)
    But in ACAD 2008, the command seems not to exist anymore…

    May some of you guys help me ?

  38. Hi everybody!

    I have a problem with these ATTIN and ATTOUT.
    that’s working in ACAD 2007, and it’s wonderful :)
    But in ACAD 2008, the command seems not to exist anymore…

    May some of you guys help me ?

  39. Hi guys,

    First of all I have to tell this is a great site, it provides lots of tips and info to Acad users.
    I would like to add my two cents: there’s a way to do what Lyn is trying to do by means of VBA, I am actually developing the code to do so. The reason I am doing this is that I work for a structural detailing firm and very often we need to update title block info on tons of drawings! so using an Excel sheet with the tag attribute and string attribute on the rows and the dwg filenames on the columns, there can be inserted all the info in a batch mode to each drawing.
    I would explain more as I have more progress on this code.
    Cheers!!

    Tony

  40. Hi guys,

    First of all I have to tell this is a great site, it provides lots of tips and info to Acad users.
    I would like to add my two cents: there’s a way to do what Lyn is trying to do by means of VBA, I am actually developing the code to do so. The reason I am doing this is that I work for a structural detailing firm and very often we need to update title block info on tons of drawings! so using an Excel sheet with the tag attribute and string attribute on the rows and the dwg filenames on the columns, there can be inserted all the info in a batch mode to each drawing.
    I would explain more as I have more progress on this code.
    Cheers!!

    Tony

  41. This is a great site!
    I have a question regarding using EXCEL with the data links in ADT 2006. I have been able to create links between individual excel cells and either text, attributes, or even property information. Once I’ve created the link, I would like to be able to use both the excel file and the drawing file as a template for other projects. I have not found a way to switch the referenced linked excel file name and location to a different one globally so that I do not have to re-link each cell when copy the files to a different project folder.
    Any thoughts on this would be helpful.

  42. This is a great site!
    I have a question regarding using EXCEL with the data links in ADT 2006. I have been able to create links between individual excel cells and either text, attributes, or even property information. Once I’ve created the link, I would like to be able to use both the excel file and the drawing file as a template for other projects. I have not found a way to switch the referenced linked excel file name and location to a different one globally so that I do not have to re-link each cell when copy the files to a different project folder.
    Any thoughts on this would be helpful.

  43. @Lyn – If you do a Save As on a DWG – chances are the handles will be duplicated. You would need to erase and re-insert the block to make AutoCAD assign it a new handle. Looking at a DWG as a database, the handle is simply the “unique key” AutoCAD assigns to each object within it.

    As for the HandleToObject method – that’s a function of the AutoCAD API. There’s a discussion forum thread which may help you out: http://discussion.autodesk.com/thread.jspa?messageID=4955666

  44. @Lyn – If you do a Save As on a DWG – chances are the handles will be duplicated. You would need to erase and re-insert the block to make AutoCAD assign it a new handle. Looking at a DWG as a database, the handle is simply the “unique key” AutoCAD assigns to each object within it.

    As for the HandleToObject method – that’s a function of the AutoCAD API. There’s a discussion forum thread which may help you out: http://discussion.autodesk.com/thread.jspa?messageID=4955666

  45. Have you come across a HandleToObject method/command? I’ve read it from some CAD blog, i forget which one though. I’m trying to find it in AutoCAD 2007 but i can’t seem to find it not even in Help..

    Thanks.

  46. Have you come across a HandleToObject method/command? I’ve read it from some CAD blog, i forget which one though. I’m trying to find it in AutoCAD 2007 but i can’t seem to find it not even in Help..

    Thanks.

  47. yeah you’re right, thank you. Sorry if i confused you. I confused myself too..

    What I really meant was that I’m trying to insert the same block, “block1” (for example), to different drawings “dwg1, dwg2, dwg3,…, dwg700” and “block1” has to have different attribute values for each drawing. That’s what i mean the handle would be duplicated.

    block handles aren’t user-defined, are they?

  48. yeah you’re right, thank you. Sorry if i confused you. I confused myself too..

    What I really meant was that I’m trying to insert the same block, “block1” (for example), to different drawings “dwg1, dwg2, dwg3,…, dwg700” and “block1” has to have different attribute values for each drawing. That’s what i mean the handle would be duplicated.

    block handles aren’t user-defined, are they?

  49. @Vanessa – Sounds to me you’re essentially doing a quantity count for each floor. If your units are blocks, this can be real easy using the EATTEXT (Extract Attribute Text) command. It will count your blocks, and can summarize them by say unit type.

    @Gary – Based on your description, I’d highly recommend using Sheet Set Manager to manage your sheets. Trust me – it’s much easier, and much more robust than this method.

    @Lyn – First while there is a chance a handle would be duplicated – it’s rare. You could probably work up a formula or something in Excel to check each handle against the others in your spreadsheet.

    No less, to do what you’re suggesting would probably mean writing a custom routine which would collect the needed attribute values, insert a new block & assign the values from your table.

  50. @Vanessa – Sounds to me you’re essentially doing a quantity count for each floor. If your units are blocks, this can be real easy using the EATTEXT (Extract Attribute Text) command. It will count your blocks, and can summarize them by say unit type.

    @Gary – Based on your description, I’d highly recommend using Sheet Set Manager to manage your sheets. Trust me – it’s much easier, and much more robust than this method.

    @Lyn – First while there is a chance a handle would be duplicated – it’s rare. You could probably work up a formula or something in Excel to check each handle against the others in your spreadsheet.

    No less, to do what you’re suggesting would probably mean writing a custom routine which would collect the needed attribute values, insert a new block & assign the values from your table.

  51. We’re trying to import the information from one spreadsheet to a bunch of blocks in different drawings, rather than blocks in one drawing.

    Is it possible that instead of exporting the block to get the handle information, you just assign one to it?

    Cause if we try to export different blocks from different drawings separately, there might be a possibility that the handle will be duplicated.

    So is it possible?

  52. We’re trying to import the information from one spreadsheet to a bunch of blocks in different drawings, rather than blocks in one drawing.

    Is it possible that instead of exporting the block to get the handle information, you just assign one to it?

    Cause if we try to export different blocks from different drawings separately, there might be a possibility that the handle will be duplicated.

    So is it possible?

  53. I use ATTIN to import title block information to groups of drawings. I enter the info into the .txt file and use ATTIN on each drawing to import the data. The problem is that I have to interactively select the block (there is always only one instance) each time. I would like to create a script or lisp file to import the data in a batch mode but the handle is different for each file. How do I work around this problem?

  54. I use ATTIN to import title block information to groups of drawings. I enter the info into the .txt file and use ATTIN on each drawing to import the data. The problem is that I have to interactively select the block (there is always only one instance) each time. I would like to create a script or lisp file to import the data in a batch mode but the handle is different for each file. How do I work around this problem?

  55. Hi-
    Your website is so helpful. I’m stumped and would love your help.

    I’m trying to do unit counts per floor in the building. I’ve created a unit tags block with attributes that contain unit type, area, and other info. I’ve been exporting data tables as excel files, and linking these files into a greater spreadsheet that says how many units per floor, how many of each type, etc.

    If I add or subtract a unit type, things get all hairy and I need to relink everything. My system requires that all of the excel data files that are coming out of CAD are in the same order each time, and adding a new unit type messes up the order of things. Is there a way to arrange the data coming out of autocad to list in the same order each time?

    Or is there a whole nother way of doing this that would be easier?

    Thanks!

  56. Hi-
    Your website is so helpful. I’m stumped and would love your help.

    I’m trying to do unit counts per floor in the building. I’ve created a unit tags block with attributes that contain unit type, area, and other info. I’ve been exporting data tables as excel files, and linking these files into a greater spreadsheet that says how many units per floor, how many of each type, etc.

    If I add or subtract a unit type, things get all hairy and I need to relink everything. My system requires that all of the excel data files that are coming out of CAD are in the same order each time, and adding a new unit type messes up the order of things. Is there a way to arrange the data coming out of autocad to list in the same order each time?

    Or is there a whole nother way of doing this that would be easier?

    Thanks!

  57. if you arbitrarily change the handle names in excel, you can manually assign the block items in the order in which they appear in your excel spreadsheet.

  58. if you arbitrarily change the handle names in excel, you can manually assign the block items in the order in which they appear in your excel spreadsheet.

  59. The answer to your question is yes and no. You have the flexibility to save your Excel file in whichever format you prefer (XLS or XLSX). What’s important is that you have a worksheet that you Save As a Tab Delimited TXT file. The TXT file is what you have to import into AutoCAD using the ATTIN command.

    It would be cool if Autodesk would expand the functionality of this command, and allow you to dynamically connect to a XLS/XLSX worksheet. Unfortunately that functionality doesn’t currently exist in the software. Perhaps the ATTOUT and ATTIN commands will “grow up” and become real AutoCAD commands in a future release of the software.

  60. The answer to your question is yes and no. You have the flexibility to save your Excel file in whichever format you prefer (XLS or XLSX). What’s important is that you have a worksheet that you Save As a Tab Delimited TXT file. The TXT file is what you have to import into AutoCAD using the ATTIN command.

    It would be cool if Autodesk would expand the functionality of this command, and allow you to dynamically connect to a XLS/XLSX worksheet. Unfortunately that functionality doesn’t currently exist in the software. Perhaps the ATTOUT and ATTIN commands will “grow up” and become real AutoCAD commands in a future release of the software.

    • Ok. Thanks for the quick reply. Have looked at another way to solve it. I
      tried to link into a range from excel with copy and paste method. I
      will then have to update data in AutoCAD from Excel. And it works! But
      when I try to update from AutoCad LT 2012 to excel by using the “Update
      to source” button I get a message;
      Command: _DATALINKUPDATE
      Select an option [Update data link/Write data link] : _W
      1 object(s) found.
      1 data link(s) do not allow their data to be written out.
      0 data link(s) written out successfully.
      How can I fix this?

    • I have block with visibility parameter. When use ATTOUT command, it’s doesn’t export visibility parameter. I want to export this parameter to to edit it, after that import to AutoCAD to control visibility of block. Do you have any solution to solved my problem.
      Thanks 

Leave a Reply