Jeff Smith of Ohio e-mailed a request to create a spreadsheet kind of table by converting tables made prior to the introduction of AutoCAD's Table command. At first, I thought this could be accomplished in AutoCAD 2008 using the data extraction method of the Table command. Data extraction is a powerful tool, but when the data is in the form of lines, polylines, text, and mtext, it is quite cumbersome and time consuming to get the data in a usable format. The solution was to write the routine MAKETABLE.LSP, which allows the user to select lines, polylines, and any type of text and convert them into an AutoCAD table object that replaces the original data. Get the Code! Download the MAKETABLE.LSP file from Cadalyst's Get the Code! library (March 2008) and save it in AutoCAD's Support directory. Use the Appload facility by selecting Tools / Load Application, then browse to select MAKETABLE.LSP.
How to Use the MAKETABLE.LSP Code To start the program, enter MTB on the Command line, and you will be prompted to "Select old table with a window: Upper left point:" followed by the prompt, "Lower right point:". The table that is made of lines, polylines, and text is automatically replaced by an AutoCAD table object that contains all original data and headers. These figures show the table before and after conversion.
|