Ibrakadabra Posted December 25, 2020 Posted December 25, 2020 Hello everyone. I have trouble to split up one dwg into other dwg which object is only inside the boundary. I have done with this method: create boundary (by closed polygon) to which object I want to save-trim outside boundary-save as the modified dwg-undo to previous dwg (so i get back my original dwg objects) and repeat to the first step. Is there any lisp to solve my problem? It takes too much time with my traditional method. Thanks in advance. Quote
marko_ribar Posted January 2, 2021 Posted January 2, 2021 You can select objects you want and WBLOCK them into separate files... Is this you are after? 1 Quote
mhupp Posted January 4, 2021 Posted January 4, 2021 Rather then using polylines for selections you can use your current view. found here https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/select-similar-for-current-window-view/td-p/848068 (defun GetScreenCoords ( / viewname viewdata vctr vwidth ctrx ctry xmin xmax ymin ymax) (command "-view" "s" "tempview") (setq viewname (tblobjname "view" "tempview") viewdata (entget viewname) vctr (cdr (assoc 10 viewdata)) vwidth (cdr (assoc 41 viewdata)) vheight (cdr (assoc 40 viewdata)) ctrx (car vctr) ctry (cadr vctr) ) (setq xmin (- ctrx (/ vwidth 2.0)) xmax (+ ctrx (/ vwidth 2.0)) ymin (- ctry (/ vheight 2.0)) ymax (+ ctry (/ vheight 2.0)) ) (setq ptlist (list (list xmin ymin) (list xmax ymin) (list xmax ymax) (list xmin ymax))) ) Quote
BIGAL Posted January 4, 2021 Posted January 4, 2021 Have a look at "cookie cutter.lsp" and Marko's suggestion together. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.