Tip 2239: Layer Table to Excel
Pedro Ferreira's Layer Table to Excel utility creates a Microsoft Excel worksheet that contains a complete dump of the current drawing's layer table. For this custom command to work, you must have Excel installed on your computer, and it should be up and running with a new, blank worksheet. Load the LISP file, then type L2X to activate. The rest is automatic. In the LISP code, Excel is connected and a new worksheet started. Visual LISP VLAX object access is used to retrieve the layer table details, and those details are written directly to the worksheet cells using Excel object access. This utility is a great example of how to connect object systems such as Excel to AutoCAD through Visual LISP.