.NET

Reply
Active Contributor
Chris_Rogers
Posts: 44
Registered: ‎06-22-2009
Message 1 of 4 (255 Views)

Setting Multiline Attribute

255 Views, 3 Replies
06-24-2013 04:56 PM

When I manually enter the attribute, it comes up with 3 different data entry options but when I look at the attribute in .NET it shows IsMTextAttribute = FALSE.

 

What is the best way to set the multiline block attribute?

-Chris Rogers
Inventor Certified Professional
________________________________________________________
If this post helps, please click the "Thumbs up"/"Kudos"
If this post gives the solution, please click "Accept as Solution"
Distinguished Contributor
HJohn1
Posts: 170
Registered: ‎09-26-2008
Message 2 of 4 (222 Views)

Re: Setting Multiline Attribute

06-25-2013 12:45 PM in reply to: Chris_Rogers

I don't know if the way I have been updating my multiline attributes is the best way to go about it.  I have probably taken some ideas from here and there.  My biggest problem was find a way to display imperial dimensions, like say 12'-3 3/4" properly formatted with diagonal fractions.  I had to format the string prior to assign it to the contents of the mtext.  Here is how I have been doing it.  I hope it gives you some ideas and perhaps other people will suggest better ways.

 

If Att.IsMTextAttribute = True Then

	Mtxt = Att.MTextAttribute

	Mtxt.Contents = "Test"

	Att.MTextAttribute = Mtxt

	Att.UpdateMTextAttribute()

End If

           

 

Active Contributor
Chris_Rogers
Posts: 44
Registered: ‎06-22-2009
Message 3 of 4 (213 Views)

Re: Setting Multiline Attribute

06-25-2013 01:25 PM in reply to: HJohn1

My problem is that the attribute has IsMTextAttribute = FALSE therefore, it would never do the logic inside your If statement.

-Chris Rogers
Inventor Certified Professional
________________________________________________________
If this post helps, please click the "Thumbs up"/"Kudos"
If this post gives the solution, please click "Accept as Solution"
*Expert Elite*
Hallex
Posts: 1,569
Registered: ‎10-08-2008
Message 4 of 4 (207 Views)

Re: Setting Multiline Attribute

06-25-2013 02:17 PM in reply to: Chris_Rogers

Hi Chris

Try example from this page

http://www.acadnetwork.com/index.php?topic=265.msg463#msg463

_____________________________________
C6309D9E0751D165D0934D0621DFF27919
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.