Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
Contributor
dkeyser
Posts: 16
Registered: ‎01-05-2006
Message 1 of 7 (1,398 Views)

Continuous dimension lisp that alternate the dimension position

1398 Views, 6 Replies
07-12-2012 07:44 AM

Is there a lisp that will allow me to do a continuous dimension, but will alternate the dimension position from low, high, low and high?  If there is no lisp already created, can someone help me to create one? 

 

See Continuous dimension attachment for example.

 

I work at a glass and glazing company and this is how we dimension mullion width and DLO. See typical window dimensioning attachment for window elevation with dimensions.


 

 

Thanks

danny

Distinguished Mentor
_Tharwat
Posts: 574
Registered: ‎07-02-2010
Message 2 of 7 (1,394 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-12-2012 08:51 AM in reply to: dkeyser

You forgot to add the  attachment .

____________________________________________________
Get learn and learn and practice , to become experienced guy .
Contributor
dkeyser
Posts: 16
Registered: ‎01-05-2006
Message 3 of 7 (1,389 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-12-2012 09:18 AM in reply to: _Tharwat

Is there a lisp that will allow me to do a continuous dimension, but will alternate the dimension position from low, high, low and high?  If there is no lisp already created, can someone help me to create one? 

 

See Continuous dimension attachment for example.

 

I work at a glass and glazing company and this is how we dimension mullion width and DLO. See typical window dimensioning attachment for window elevation with dimensions.


 

 

Thanks

danny

Contributor
dkeyser
Posts: 16
Registered: ‎01-05-2006
Message 4 of 7 (1,388 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-12-2012 09:20 AM in reply to: _Tharwat

Is there a lisp that will allow me to do a continuous dimension, but will alternate the dimension position from low, high, low and high?  If there is no lisp already created, can someone help me to create one? 

 

See Continuous dimension attachment for example.

 

I work at a glass and glazing company and this is how we dimension mullion width and DLO. See typical window dimensioning attachment for window elevation with dimensions.


 

 

Thanks

danny

*Expert Elite*
scot-65
Posts: 2,124
Registered: ‎12-11-2003
Message 5 of 7 (1,367 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-12-2012 04:01 PM in reply to: dkeyser

This is a snippet of code we use that can be altered to your needs.

If anyone else wishes to pipe in and finish it, be my guest as I do

not have time right now to tinker with it...

 

 (defun DIMPNTS ( / PTX PTS PLST DLPT )
  (setq PTS (getpoint "Select all points: "))
  (setq PLST (list PTS))
  (while (setq PTS (getpoint PTS))
   (setq PLST (append PLST (list PTS)))

  );while
  (setq DLPT (getpoint "\nSelect dimension line location: "))
  (setq PTX (car PLST)) (setq PLST (cdr PLST))
  (foreach PTS PLST
   (command ".dim" USERDM PTX PTS DLPT "" "exit") ;<-- this area requires rework to fit the OP's needs
   (setq PTX PTS)
  );foreach
 );endDIMPNTS

 

What the above does:

Similar to dim continue, first select desired dimension line extension end points, then [Enter], then select

where the dimension line will be located. The foreach will do a "Dim1" and reuse the dimension

line location value. This snippet is part of a whole dimensioning utility that was original to our office

way back when we had R12 (meaning I was not the original author of this section of code).

 

Where:

- USERDM is "Hor", "Ver", etc. as found in the dim command (the gremlin).

- DLPT is the dimension line location.

 

To do:

- Preset or input offset distance of the dimension lines.

- Optional to place first dimension as the higher line (default), or lower line.

- Add a counter and determine if number is even or odd - this will determine location of next dimension...

 

???

Scot-65
Dyslexia is a permanent physical disability that cannot be seen.
*Expert Elite*
scot-65
Posts: 2,124
Registered: ‎12-11-2003
Message 6 of 7 (1,337 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-13-2012 03:18 PM in reply to: dkeyser

OK, I found a little time, restructured the snippet into a full command, and did minor testing.

Because of the program structure (with a command inside), an *error* handler was not required.

Adjust "c1" as needed (currently it is 10).

 

DMZ01.gif

 

DMZ.lsp - Dimension Zigzag. Horizontal or Vertical orientation. DYNmode friendly. Orientation retained in current session.

 

I also thought of using DMST as a possible name "Saw Tooth" or "Stagger"...

 

Have Fun!

 

Scot-65

 

Scot-65
Dyslexia is a permanent physical disability that cannot be seen.
Contributor
dkeyser
Posts: 16
Registered: ‎01-05-2006
Message 7 of 7 (1,304 Views)

Re: Continuous dimension lisp that alternate the dimension position

07-18-2012 11:17 AM in reply to: dkeyser

thanks

 

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community