Author Topic: need some help to play with "Dim"  (Read 3381 times)

0 Members and 1 Guest are viewing this topic.

lqh610

  • Mosquito
  • Posts: 1
need some help to play with "Dim"
« on: May 25, 2010, 05:42:19 PM »
hi all, i need a lisp.Cant explain by E . So pls see dwg below

Lee Mac

  • Seagull
  • Posts: 12255
  • London, England
Re: need some help to play with "Dim"
« Reply #1 on: May 25, 2010, 06:07:40 PM »
hi all, i need a lisp.Cant explain by E . So pls see dwg below

What, you think this is a LISP supermarket?

ronjonp

  • Needs a day job
  • Posts: 7025
Re: need some help to play with "Dim"
« Reply #2 on: May 25, 2010, 06:20:55 PM »
Looks like QDIM.

Windows 10 x64 - AutoCAD /C3D 2020

Custom Build PC

CmdrDuh

  • Automatic Duh Generator
  • King Gator
  • Posts: 4039
Re: need some help to play with "Dim"
« Reply #3 on: May 25, 2010, 06:24:16 PM »
hi all, i need a lisp.Cant explain by E . So pls see dwg below

What, you think this is a LISP supermarket?
:-D :-D :-D :-D :evil:
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second

gile

  • Water Moccasin
  • Posts: 2224
  • Marseille, France
Re: need some help to play with "Dim"
« Reply #4 on: May 26, 2010, 02:17:47 AM »
Quote
What, you think this is a LISP supermarket?

No, in a supermarket, you're supposed to pay for what you get...
Speaking English as a French Frog

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #5 on: May 26, 2010, 04:43:56 AM »

Perhaps his lack of English precludes the refinement to make the request for help more acceptable.

lqh610,
Can you explain what you need help with ??
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #6 on: May 26, 2010, 05:00:31 AM »

I see that your drawing explains your wishes quite well.

I believe the TAB key option is not required .. seperate commands would be more efficient and more economical to produce.

Are you using AC2004 ??


The continue can be achieved simply ;

Command: DIM
Dim: continue
Specify a second extension line origin or [Select] <Select>: s
Select continued dimension:
Specify a second extension line origin or [Select] <Select>:
Enter dimension text <48.12>:

Dim: *Cancel*

The remainder would require some simple code to do the job.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #7 on: May 26, 2010, 05:26:58 AM »


This will change the leg length manually ... pretty easy :)

See the attached Picture
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #8 on: May 26, 2010, 05:31:20 AM »

for the second Item in your wish list;

You'll need to program so that ;

You select the dimension to divide.
Select the NEW location for the additional extension Line.
Add 2 dimensions programmatically using information extracted from the selected dimension
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #9 on: May 27, 2010, 11:44:10 PM »
I thought this was worth coding for our own use, SO ....

Have a play with this.

Code: [Select]
(defun c:Split_Dims (/ sel newpt ent edata elist)

;; codehimbelonga KerryBrown@theSwamp 2010.05.28

  (if (and (setq sel (entsel "\nSelect Dimension to Split."))
           (setq newpt (getpoint "\Select new Dim Point"))
      )
    (progn (setq ent   (car sel)
                 edata (entget ent)
                 elist (vl-remove-if
                         '(lambda (pair)
                            (member (car pair)
                                    (list -1 2 5 102 310 300 330 331 340 350 360 410)
                            )
                          )
                         edata
                       )
           )
           (entmod (subst (cons 14 newpt) (assoc 14 elist) edata))
           (entmakex (subst (cons 13 newpt) (assoc 13 elist) elist))
    )
  )
  (princ)
)

Code added:
« Last Edit: May 28, 2010, 12:47:34 AM by Kerry Brown »
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #10 on: May 27, 2010, 11:47:08 PM »

... and a piccy to show it in action ..

Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #11 on: May 28, 2010, 12:24:02 AM »


and try this for the LegLength Modification

Code: [Select]
(defun c:LegLengthMod ( / ss dimobjs)

;; codehimbelonga KerryBrown@theSwamp 2010.05.28

  (vl-load-com)
  (if (and (setq ss (ssget '((0 . "DIMENSION"))))
           (setq dimobjs (mapcar 'vlax-ename->vla-object
                                 (vl-remove-if 'listp (mapcar 'cadr (ssnamex ss)))
                         )
           )
      )
    (foreach dim dimobjs
      (vla-put-extlinefixedlensuppress dim :vlax-true)
      (vla-put-extlinefixedlen dim (* 2 (vla-get-textheight dim)))
    )
  )
  (princ)
)

Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #12 on: May 29, 2010, 08:31:43 PM »

lqh610 ,
were you able to understand the code and use it ??
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: need some help to play with "Dim"
« Reply #13 on: May 31, 2010, 05:57:21 AM »

I really DO enjoy talking to myself  :-P
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

--> Donate to theSwamp<--

Lee Mac

  • Seagull
  • Posts: 12255
  • London, England
Re: need some help to play with "Dim"
« Reply #14 on: May 31, 2010, 06:52:54 AM »
I thought this might happen...