I am looking for a way to extract text data out of an Excel spreadsheet and put it into a DWG.
I am hoping that there is a way (maybe through a FIELD) where I can have a text box sitting in an AutoCAD file, which once linked to an excel, will be populated with the text data that is in a particular cell.
So I am imagining that I have a standard Excel file that can be filled out by a 3rd party. Then once it has been linked, each cell of information will appear in the corresponding MTEXT box.
I have looked into the tables way of doing this, but I am still hopeful there is another way to get this to work.
Thanks for your time,
Nick Gaulke
Solved! Go to Solution.
Solved by ChicagoLooper. Go to Solution.
Extracting Cell data to a field is only possible as long as the content of the cell is strictly numerical
Refer to this previous post on this topic : Mleader with datalink as text
SALMANUL FARIS
From what you're describing you can use a 'datalink' also known as linking an AutoCAD TABLE to a spreadsheet. It would be a 1-row x 1-column table in AutoCAD that's linked to a single cell in a sreadsheet. Because a third party will be the input source supplying data to the spreadsheet, you have no way of controlling the number of 'lines' in the cell, e.g. will it be one word, one sentence or one paragraph. You could give rules to the third party, but you don't have a means to enforce them and the third will do whatever they want without fear of retribution. You also will have to vary the size of your 1-cell table, i.e. the width will vary depending on the content and if it's too narrow, the content will be partially hidden. Make the table too wide and the table becomes inefficient occupying extraneous space. Having 'others' be direct contributors, or authors, to your drawing cannot, and should not, be considered a Best Practice and should be avoided, otherwise, you run the risk of losing control over content. There may be other options to achieve what you want but they can only be considered if you provide full and complete disclosure on your drawing, on your current work flow and your target outcome.
Chicagolooper
From what you have described, I think that I will be able to use a DATALINK.
Thank you for all of your advice, I will look further into how a DATALINK works and see if it is suits my application.
I appreciate you warning me about working with a 3rd party, it will definitely need some more consideration on my part.
Cheers again
Has there been any changes on this topic? Is there a way to accomplish this with AutoLisp? If so, can it be in either AutoCAD or AutoCAD LT?
Can't find what you're looking for? Ask the community or share your knowledge.