Jump to content

Recommended Posts

Posted (edited)

Hello Everyone,

 

I just want to share small lisp routine. Maybe someone find it usefull.

Any comments and suggestions are welcome.

 

 

kruuger

 

V1.03

capture-5.gif

Spider-1.03.png

Spiderdim.lsp

Spiderdim.dcl

Edited by kruuger
  • Replies 22
  • Created
  • Last Reply

Top Posters In This Topic

  • BlackBox

    4

  • alanjt

    3

  • catoscuro

    3

  • blueshake

    1

Top Posters In This Topic

Posted Images

Posted

thank you for your share.from the show,it seems it is used find matched texts in dimension.??

Posted
thank you for your share.from the show,it seems it is used find matched texts in dimension.??

yes, lisp go thru dims and mark them with lines (spider). it is much better then selection set from autocad find command and not disappear after screen regeneration.

 

kruuger

Posted

Just curious... Why not change the color of a selection set of dims instead (no spider)?

 

(vla-put-color <object> <color>) 

 

 

Then your 'marked' selection is not lost after a regen.

Posted
Just curious... Why not change the color of a selection set of dims instead (no spider)?

 

(vla-put-color <object> <color>) 

Then your 'marked' selection is not lost after a regen.

Personally i do not prefer any modification to drawing (like making additional layers, changing object properties until it is really necessary).

I agree that put-color will be faster but i also want play with grread. I'm still rookie with this.

 

Thanks for interesting

kruuger

Posted
A very great work kruuger.

 

Wish you best of luck.

 

Tharwat

Thanks tharwat113.

I wish to add nested dimension or xref. But for now looks like it is beyond my lisp knowledge.

 

kruuger

Posted

What if the text is within the Prefix/Suffix (set in style) instead of TextOverride?

Posted
What if the text is within the Prefix/Suffix (set in style) instead of TextOverride?

aaa good catch Alan. I don't even think about this (my brain is to small).

i see what i can do with this.

 

thanks

kruuger

Posted

Bardzo ladnie Ci to wyszlo.

Very nice done. Thank you.

Posted
Personally i do not prefer any modification to drawing (like making additional layers, changing object properties until it is really necessary).

I agree that put-color will be faster but i also want play with grread. I'm still rookie with this.

 

No worries. :)

 

Please do not misunderstand me, I have *some* proficiency using LISP, but I am a complete novice with DCL (I've never tried it!). You have done a great job in that regard.

 

Good luck!

Posted
Bardzo ladnie Ci to wyszlo.

Very nice done. Thank you.

Haha, Dzieki :)

Thanks

 

No worries. :)

 

Please do not misunderstand me, I have *some* proficiency using LISP, but I am a complete novice with DCL (I've never tried it!). You have done a great job in that regard.

 

Good luck!

Of course not :) So I learn a lot from your LISP code many times. Any help with DCL just ask.

 

progress....

capture-8.gif

Posted
Of course not :) So I learn a lot from your LISP code many times. Any help with DCL just ask.

 

 

Thanks, that is very kind of you. :)

Posted

kruuger,

I hope you don't mind and I haven't stepped on your toes (if I have I apologize and will promptly remove my snippet), but I was killing time over the weekend and thought I'd scratch this out as a very simple demo...

 

(defun c:DimSearch (/ flt lst n gr)
 ;; Alan J. Thompson, 09.27.10
 (vl-load-com)
 (if (and (/= "" (setq flt (strcase (getstring T "\nSpecify search filter: "))))
          (princ "\nSelect dimensions to search <All>: ")
          ((lambda (ss / dims ss)
             (if (setq dims (cond ((ssget '((0 . "DIMENSION"))))
                                  ((ssget "_X" '((0 . "DIMENSION"))))
                            )
                 )
               (progn
                 (vlax-for x (setq dims (vla-get-activeselectionset
                                          (cond (*AcadDoc*)
                                                ((setq *AcadDoc* (vla-get-activedocument
                                                                   (vlax-get-acad-object)
                                                                 )
                                                 )
                                                )
                                          )
                                        )
                             )
                   (if (vl-member-if
                         (function (lambda (s) (wcmatch s flt)))
                         (mapcar (function (lambda (p) (strcase (vlax-get-property x p))))
                                 '(TextOverride TextPrefix TextSuffix)
                         )
                       )
                     (setq lst (cons (trans (vlax-get x 'TextPosition) 0 1) lst)
                           ss  (ssadd (vlax-vla-object->ename x) ss)
                     )
                   )
                 )
                 (vla-delete dims)
                 (sssetfirst nil ss)
                 (ssget "_I")
               )
             )
           )
            (ssadd)
          )
          (setq n -1)
     )
   (while (and (eq 5 (car (setq gr (grread T 15 0)))) (vl-consp (cadr gr)))
     (redraw)
     (foreach p lst (grdraw (cadr gr) p 1))
   )
 )
 (redraw)
 (princ)
)

Posted
kruuger,

I hope you don't mind and I haven't stepped on your toes (if I have I apologize and will promptly remove my snippet), but I was killing time over the weekend and thought I'd scratch this out as a very simple demo...

You guys making crazy stuff here. I always want to see another solution. There is lot to learn from your code. Maybe i can "steal" some line from your code :wink:

kruuger

Posted
You guys making crazy stuff here. I always want to see another solution. There is lot to learn from your code. Maybe i can "steal" some line from your code :wink:

kruuger

Go for it; that's why I posted.
Posted
Go for it; that's why I posted.

 

Isn't it wonderful...?

 

The leaves are changing... winter will be here before you know it... and Alan (this whole time) is sharing his Christmas spirit (and code) with others. :P

  • 4 weeks later...
  • 4 years later...
Posted

please update to autocad2015, thanks

Guest kruuger
Posted
please update to autocad2015, thanks

any errors ?

try (vl-load-com) first and than spider.

kruuger

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...