Community
Hi
A lisp in needed that SLICE 3D model and Put the FACE to a 2d View dwg
as sample dwg are attached
Thanks in advance
Solved! Go to Solution.
Solved by hosneyalaa. Go to Solution.
try @arshadmirza786
vl-load-com)
;; https://help.autodesk.com/view/OARX/2022/ENU/?guid=GUID-FB1253E1-770C-4685-8EE4-81D241F405D8
(defun c:Example_SectionSolid()
;; This example creates a box in model space.
;; It then sections the box based on a plane
;; defined by three points. The section is returned
;; as a region.
(setq acadObj (vlax-get-acad-object))
(setq doc (vla-get-ActiveDocument acadObj))
;; Define the box
(setq center (vlax-3d-point 5 5 0)
boxLength 5
boxWidth 7
boxHeight 10)
;; Create the box (3DSolid) object in model space
(setq modelSpace (vla-get-ModelSpace doc))
(setq boxObj (vla-AddBox modelSpace center boxLength boxWidth boxHeight))
;; Define the section plane with three points
(setq sectionPt1 (vlax-3d-point 1.5 7.5 0)
sectionPt2 (vlax-3d-point 1.5 7.5 10)
sectionPt3 (vlax-3d-point 8.5 2.5 10))
;; Section the box
(setq sectionObj (vla-SectionSolid boxObj sectionPt1 sectionPt2 sectionPt3))
;; Change the viewing direction of the viewport
(setq NewDirection (vlax-3d-point -1 -1 1))
(setq activeViewport (vla-get-ActiveViewport doc))
(vla-put-Direction activeViewport NewDirection)
(vla-put-ActiveViewport doc activeViewport)
(vla-ZoomAll acadObj)
)
Can't find what you're looking for? Ask the community or share your knowledge.