Print Page | Close Window

Lisp to Generate Section Plane Geometry

Printed From: CAD Forum
Category: EN
Forum Name: AutoCAD
Forum Description: Discussion about AutoCAD and AutoCAD LT, viewers, DWG and DWF formats, Design Review, AutoCAD 360, add-ons
URL: https://www.cadforum.cz/forum_en/forum_posts.asp?TID=4898
Printed Date: 31.May.2026 at 18:09


Topic: Lisp to Generate Section Plane Geometry
Posted By: j.smith
Subject: Lisp to Generate Section Plane Geometry
Date Posted: 03.Dec.2010 at 17:08

What I’m trying to accomplish with my limited knowledge of Lisp:

 

I have a section plane already inserted in my drawing with the proper settings selected to generate and replace an existing 2D block. The section plane is on layer “W-SECT-LOW”.

I’m trying to make a shortcut lisp that will bring up the Generate Section/Elevation Dialog Box and automatically select the section plane on this layer, and then execute “C” for create.

 

This is what I have so far:

 

(command "sectionplanetoblock" (ssget "_X" '((8 . "W-SECT-LOW"))))

 

It brings up the Dialog Box with the “select section plane” button highlighted. After I press the spacebar it recognizes my section plane has already been selected, then I press “C” and it creates the 2D block.

Can anyone help me add to this so I won’t have to press “spacebar” and “C”??  

-Thank you



Print Page | Close Window