Jump to content

Leader with Text


RepCad

Recommended Posts

Hi all, 

I'm using this code to add leader with two points. it's working correct, but is it possible to create leader with Text (instead of Mtext)?

Manually I do it with "Explode" command, but the bottom line of text is cleaned afterwards. 

 


(setq	pt1   (getpoint "\nFirst point: ")
	pt2   (getpoint pt1 "\nNext point: ")
	space (vla-get-modelspace
		(vla-get-activedocument (vlax-get-acad-object))
	      )
  )

  (setq pt3 (polar pt2 0.0 2))

  (setq ptlist (apply 'append (list pt1 pt2)))
  (setq txtobj (vla-addmtext space (vlax-3d-point pt3) 10 "Checked-Send"))
  (setq txent (entlast))
  (setq	ldrobj
	 (vlax-invoke space 'addleader ptlist txtobj acLineWithArrow)
  )

 

Link to comment
Share on other sites

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