Jump to content

Recommended Posts

Posted (edited)

Hi all guys, I wrote a simple code to make leader with x,y coordinates and it's working well but when I explode or delete mtext of leader, the botton line of the mtext  is automatically cleared, (I explode mtext because I want to convert it to text)

 

(defun c:ldd ()

  (setq p1 (getpoint "\npick a point :"))
  (setq p2 (getpoint "\npick a secound point :"))

  (setq x (car p1))
  (setq y (cadr p1))

  (setq sx (rtos x))
  (setq sy (rtos y))

  (setq text (strcat "X=" sx " \nY=" sy))

  (command "leader" p1 p2 "" text "")
)

 

Can someone give me a solution??

 

aa.thumb.gif.24f1fa56dd64e45d6c7acc88ade0fc7c.gif

 

 

Edited by amir0914
  • Like 1
Posted

Without a drawing (AutoCAD 2010 format) containing an MLeader I can't provide a solution. As to why, it is because the textleftattachment is set to underline bottom of text, If you explode the leader or delete the text there is no associated text to underline

  • Like 1
Posted

Perhaps you could explain the next step as to why you explode the leader, is it that you want to move or get the co-ordinates ?

  • Like 1

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...