LISP Routine to pull attributes from block on click
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi all,
I am wondering if someone can help with the following. I am trying to create a LISP command for checking ducting/cabling routes that lets me:
1) Run command 'CHECK'
2) Click on a block (or 'Start Point'), LISP pulls an attribute (in this case called '0') out of that block. In the attached CAD file the block is '0PE PILLAR-STATION'
3) Draw in the cable/duct with a polyline route then hit space.
4) Clock on a second block (or 'End Point'), LISP pulls second attribute (also '0') out of that block. ie. second block called '0PE PILLAR-STATION'
5) LISP writes the 'Start Point', 'End Point', length of polyline, and layer name to attributes in a block that I can place somewhere in the drawing.
6) End of LISP
If I am able to get a block with these attributes I can then use attout and copy into an excel spreadsheet as a BOQ.
Lisp called 'Check' is attached along with cad file. This is a modification of LeeMac's 'Midlen' which writes the line length to the middle of a polyline.
Hopefully the above is understandable.
Cheers,
Aaron.