Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/25/2021 in all areas

  1. Try this ; copy an object to multi rectangs ; based on Lower Right cnr of rectang ; By AlanH Jan 2021 (defun c:test ( / ss lst co-ord ent pt x ) (setq ss (ssget (list (cons 0 "LWpolyline")))) ; select all the rectangs 1st (setq lst '()) (repeat (setq x (sslength ss)) (setq ent (ssname ss (setq x (- x 1)))) (setq co-ord (mapcar 'cdr (vl-remove-if-not '(lambda (x) (= (car x) 10)) (entget ent)))) (setq co-ord (vl-sort co-ord '(lambda (a b) (cond ((< (car a) (car b))) ((= (car a) (car b)) (< (cadr a) (cadr b))) ) ) )) (setq pt (list (car (nth 2 co-ord))(cadr (nth 2 co-ord)) 0.0)) (setq lst (cons pt lst)) ) (princ "\n") (princ "\nSelect objects to copy ") (setq ss (ssget)) ; select all the objects to copy (setq pt (getpoint "\nPick base point LR ? ")) (repeat (setq x (length lst)) (setq pt2 (nth (setq x (- x 1)) lst)) (command "copy" ss "" pt pt2) ) (princ) )
    2 points
  2. I forgot to say also is that the red rectangles are a combination of line objects and are not LWpolyline objects.
    1 point
  3. Having a bit of spare time, I thought I would make a hatch pattern similar to the OS marsh block marsh1.pat
    1 point
×
×
  • Create New...