Author Topic: Change arrowhead dimension  (Read 3531 times)

0 Members and 1 Guest are viewing this topic.

LE

  • Guest
Change arrowhead dimension
« on: February 23, 2006, 10:36:52 PM »
A small routine, that still requires more work, but can be handy.

Select a point closed to the arrowhead, needed to be changed... to Dot or Closed Filled [toggle]

I did it to help a cad person on the adesk customization ng...

HTH.

Code: [Select]
;; February 2006 by www.geometricad.com
(defun C:CHARROW  (/ data ename elist pt obj p10 p11 p13 p14)
  (if (and
(setq data
       (entsel "\nSelect arrowhead of dimension to change: "))
(setq ename (car data))
(eq (cdadr (setq elist (entget ename))) "DIMENSION")
(setq pt (osnap (cadr data) "_end")))
    (progn
      (setq obj (vlax-ename->vla-object ename)
    p10 (cdr (assoc 10 elist))
    p11 (cdr (assoc 11 elist))
    p13 (cdr (assoc 13 elist))
    p14 (cdr (assoc 14 elist)))
      (if (< (distance pt p10) (distance pt p13))
(vla-put-Arrowhead2Type
  obj
  (if (eq (vla-get-Arrowhead2Type obj) acArrowDefault)
    acArrowDot
    acArrowDefault))
(vla-put-Arrowhead1Type
  obj
  (if (eq (vla-get-Arrowhead1Type obj) acArrowDefault)
    acArrowDot
    acArrowDefault)))))
  (princ))
(princ)

PITCHBLACK98

  • Guest
Re: Change arrowhead dimension
« Reply #1 on: December 13, 2013, 09:42:19 AM »
I didn't want to start a new post and was a little apprehensive about bringing this thread back from 2006, but I am trying to find a way to quickly change dimension arrows...  I have to change the arrows whenever they don't fit inside the dim and cross over each other.  It's a pain to change them in the properties when you don't know which is Arrow 1 or Arrow 2.  I always dimension left to right & bottom to top, but others are very random when they dimension.  It seems like I guess wrong more often then I do right and feel like I'm changing arrows back and forth constantly all day.

This routine isn't working quite right.  Sometimes it will change the arrow I click on like its supposed to and sometimes it will change the opposite arrow.  I haven't been able to produce any particular instance that causes it to change the other arrow.  It just seems to be very random.

I'm not sure if the LISP needs to be updated or changed up a bit to work in AutoCAD 2014.  I tried changing it up to get it to work, but nothing made a difference.  Any ideas or possible another solution for this problem?

LE3

  • Guest
Re: Change arrowhead dimension
« Reply #2 on: December 14, 2013, 01:35:53 PM »
Wow and old routine.

I tested what I did back then on A2014 and works.

It expects to get the selection closed to the desired arrow to be changed.

HTH

PITCHBLACK98

  • Guest
Re: Change arrowhead dimension
« Reply #3 on: January 13, 2014, 09:00:32 AM »
Haven't had a chance to get back to this thread yet, but I think I have an idea of what it is doing.  It seems to only happen on small dims less than a foot.  If I zoom in close to the dim and click on the arrow I want to change close to the extension line it seems to work fine.  I can work with that.  Thanks!