CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz]
Cesky English Deutsch
Login/Register:
 Visitors: 2496 

CAD tip CAD tip # 7959:

Question CAD 
 %  platform  category 
Q - question

How to add layer description in AutoLISP?

A - answer You can modify layer descriptions (comments) with VisualLISP.

First make sure the COM support is loaded:

(vl-load-com)
Then use the following code (example) to add/change the description for the layer named "Lay1":
(vla-put-description (vlax-ename->vla-object (tblobjname "LAYER" "Lay1")) "My description for Lay1")
You can use this code in your own LISP routines, scripts or menu macros.
ACAD
100% *  CAD 
7.5.2011    6814×  
Prices - CAD eShop:
applies to: AutoCAD ·

See also:
Tip 12526:BufZone - buffer zones and wipeouts around AutoCAD line objects.
Tip 12368:Gaps - how to find loose ends on lines in a DWG?
Tip 12287:AutoCAD hatch flood-fill does not honor all boundaries.
Tip 12279:PropByLayer - an inverse function to SetByLayer.
Tip 12237:UnfoldRS - unfold 3D surfaces to 2D in AutoCAD.


Back   All CAD Tips All CAD tips&tricks



Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   



Featuring:
DwgTextTranslator translates a series of drawings from one language to another using MS Access.
Download a fully functional trial version.


Please use these tips at your own risk.
CAD Studio is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist