Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Multileaders do not update their under-lines when changing its Texts

7 REPLIES 7
SOLVED
Reply
Message 1 of 8
alexKoshman
409 Views, 7 Replies

Multileaders do not update their under-lines when changing its Texts

Hello to everybody here!

 

Could someone help me with this problem?

 

Text content is DXF code 304 of the MLeader entity.

When I change it via LISP text is changing but the horizontal line of the MLeader stills as it were before...

It even could be broken if the length of old and new texts is different...

 

I tried "(redraw en)" and even "(vla-update ...)" but without any benefit...

 

Thank you all for your help!

7 REPLIES 7
Message 2 of 8
Lee_Mac
in reply to: alexKoshman

Does a REGEN fix the problem?

Message 3 of 8
alexKoshman
in reply to: Lee_Mac

No, unfortunately, it doesn't...

: ((

Message 4 of 8
pbejse
in reply to: alexKoshman

would it be too much to ask to post your code here? or perhaps your MLEADER style is at fault
Message 5 of 8
alexKoshman
in reply to: pbejse

1. Draw a Multileader with LONG text like "abcdefg" with "Underline top line" Leader connection style.

(setq en (car (entsel)))
(setq el (entget en))
(setq el (subst (cons 304 "abc") (assoc 304 el) el))
(entmod el)

 2. Run this simple code and see what will happen with this SHORT text for example...

: ((

Message 6 of 8
pbejse
in reply to: alexKoshman

Hows about

 

(setq en (car (nentselp)))
(vla-put-textstring (vlax-ename->vla-object en) "abc")

 

or even

 

(setq en (car (entsel)))
(vla-put-textstring (vlax-ename->vla-object en) "abc")

 

Message 7 of 8
alexKoshman
in reply to: pbejse

YESSS!..

Thank you, pbejse!

 

I only thought It can be done within "old good" AutoLISP.

Now I understand that it could be done only with ActiveX methods (because MLeader is a "VERY NEW ENTITY")...

Message 8 of 8
alexKoshman
in reply to: alexKoshman

Thank you, pbejse, thanks again!
; ))

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost