Results 1 to 2 of 2

Thread: LISP to create multileader - content not working

  1. #1
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default LISP to create multileader - content not working

    Hi gang,

    I've got this routine almost working.

    Code:
    (vl-load-com)
    (defun c:GRDG (/ CLA)
    (setq CLA (getvar "CLAYER"))
    (command "layer" "m" "L-ANNO TEXT" "c" "1" "L-ANNO TEXT" "")
    (Steal "SW Mleader Styles.dwg"'(("Multileader Styles"("SW ML-TXT GRDG"))))
    (setvar "CMLEADERSTYLE" "SW ML-TXT GRDG")
    (command "_.mleader" "O" "C" "M" "X" (while (> (getvar 'CmdActive) 0) (command pause)))
    (setvar "CLAYER" CLA)
    (princ)
    )
    The issue is that when it comes to entering the text, it is happening down at the command line and not at the end of the landing.
    Also, even though the content should be MTEXT, it exits the command as soon as I enter a SPACE in the text.

    Any guidance is appreciated

  2. #2
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Re: LISP to create multileader - content not working

    Ok,

    I got it...

    Code:
    (vl-load-com)
    (defun c:GRDG (/ CLA)
    (setq CLA (getvar "CLAYER"))
    (command "layer" "m" "L-ANNO TEXT" "c" "1" "L-ANNO TEXT" "")
    (Steal "SW Mleader Styles.dwg"'(("Multileader Styles"("SW ML-TXT GRDG"))))
    (setvar "CMLEADERSTYLE" "SW ML-TXT GRDG")
    (initcommandversion 2)
    (command "_.mleader" "O" "C" "M" "X" (while (> (getvar 'CmdActive) 0) (command pause)))
    (setvar "CLAYER" CLA)
    (princ)
    )

Similar Threads

  1. 2012: MULTILEADER with custom block not working (Architecture 2013)
    By bamckenzie69 in forum ACA General
    Replies: 2
    Last Post: 2013-04-12, 08:48 PM
  2. how to find multileader using Lisp?
    By Macieto in forum AutoLISP
    Replies: 2
    Last Post: 2010-10-11, 12:51 PM
  3. Multileader lisp help (mtext problem)
    By framedNlv in forum AutoLISP
    Replies: 11
    Last Post: 2010-08-09, 11:13 PM
  4. Match Multileader Content
    By rolibolibo in forum AutoLISP
    Replies: 6
    Last Post: 2009-10-07, 06:12 PM
  5. Replies: 8
    Last Post: 2007-05-18, 06:55 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •