Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Changing Multiline style on existing mline

6 REPLIES 6
Reply
Message 1 of 7
Anonymous
10143 Views, 6 Replies

Changing Multiline style on existing mline

Hi,

Is there a way to change the  mline style of an existing line?  It is greyed out, but is there a system variable that could be changed to make this work?

 

Thanks

 

Russell

 

mline style.jpg001.jpg

 

6 REPLIES 6
Message 2 of 7
maciejwypych
in reply to: Anonymous

Message 3 of 7
Soyoung.H
in reply to: Anonymous

Yes, this is as designed.

 

If you want to send a wishlist to enhance program features, please click the page below.

http://usa.autodesk.com/adsk/servlet/index?siteID=123112&id=1109794

 



Soyoung.H
Message 4 of 7
braudpat
in reply to: Anonymous

 

Hello from France

 

Welcome to the Autodesk/AutoCAD Forums !

 

Not sure to well understand your question/topic !?

 

But if you want to change the style of ONE existing MLine, I have the correct VLisp routine ?

 

;; VLisp Routine :  Change_MLine
;; Change THE selected MLine to the CURRENT MLine style
;; and you can switch to Closed/Opened MLine ...

 

I hope it will help you ...

 

 
;;
;; http://cadxp.com/index.php?/topic/34672-remplacer-multiligne-par-une-autre-multiligne/page__pid__188...
;; Change_MLine par Bonuscad - Version 1.00
;; Remplacer une MLine par une autre qui utilise le style de MLine courant
;;  

;; 
;; VLisp Routine :  Change_MLine
;; Change THE selected MLine to the CURRENT MLine style
;; and you can switch to Closed/Opened MLine ...
;; 
;; Minimum Translation for US/English Forums by Patrice BRAUD
;; 
 
(vl-load-com) 

(defun l-coor2l-pt (lst flag / )
  (if lst
    (cons
      (list
        (car lst)
        (cadr lst)
        (if flag
          (+ (if (vlax-property-available-p ename 'Elevation) (vlax-get ename 'Elevation) 0.0) (caddr lst))
          (if (vlax-property-available-p ename 'Elevation) (vlax-get ename 'Elevation) 0.0)
        )
      )
      (l-coor2l-pt (if flag (cdddr lst) (cddr lst)) flag)
    )
  )
)

(defun c:Change_MLine ( / js ent ename l_pt cur_lay closed) 

; (princ "\nSélectionner une multiligne.") 
  (princ "\nPlease Select a MLine ") 

  (while (null (setq js (ssget "_+.:E:S" '((0 . "MLINE"))))) 

;   (princ "\nCe n'est pas une multiligne!") 
    (princ "\nThis is not a MLine ! ") 

  )
  (setq
    ent (ssname js 0)
    ename (vlax-ename->vla-object ent)
    l_pt (l-coor2l-pt (vlax-get ename 'Coordinates) T)
    cur_lay (getvar "CLAYER")
  ) 

;;  (initget "Fermée Ouverte _Closed Open")
;;  (if (eq (getkword "\nMultiligne [Fermée/Ouverte] <Ouverte>: ") "Closed")

    (initget "Closed Open")
    (if (eq (getkword "\nMLine [Closed/Open] <Open>: ") "Closed")

    (setq closed T)
  )
  (setvar "clayer" (vlax-get ename 'Layer))
  (command "_.mline")
  (foreach n l_pt (command "_none" (trans n 0 1)))
  (if closed (command "_close") (command ""))
  (entdel ent)
  (setvar "CLAYER" cur_lay)
  (prin1)
)

 

Patrice ( Supporting Troops ) - Autodesk Expert Elite
If you are happy with my answer please mark "Accept as Solution" and if very happy please give me a Kudos (Felicitations) - Thanks

Patrice BRAUD

EESignature


Message 5 of 7
ulisesge
in reply to: braudpat

and for all mlines in the draw?, something like modify dim style or text style?, something update all mlines once time?

Tags (1)
Message 6 of 7

You can't even modify the style if there is an existing MLINE using that style in the drawing.  You have to delete all lines using that style or create a new style.  Would seriously be helpful to be able to just edit the style from the dropdown in the properties palette then have to delete or redraw all lines. 

Message 7 of 7
pendean
in reply to: jbrandenberge

@jbrandenberge you can share your thoughts and program improvements for a tool they've ignored for 20+years here https://www.autodesk.com/company/contact-us/product-feedback

Or use a variant of AutoCAD that offers other tools for that same effect, or start using Dynamic Blocks for the same effect.

HTH

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

Post to forums  

Autodesk Design & Make Report

”Boost