.NET

Reply
Contributor
Amrit.shr
Posts: 13
Registered: ‎03-14-2011
Message 1 of 4 (224 Views)

new line with vbCrLf is not work?

224 Views, 3 Replies
03-13-2012 12:18 AM

Dear All,

To write for Single line text

in VB6 when we use vbCrLf it work and come in new line  but in .net it is not working

is therre any other way to do same thing.

          

            Dim Str1 As String = " This is Test for First Line"
            Dim str2 As String = " This is Test for Second Line"
            Dim Str3 As String = Str1 & vbCrLf & str2

            Dim acText As DBText = New DBText()
            acText.SetDatabaseDefaults()
            acText.Position = ed.GetPoint("click Point To Insert").Value
            acText.Height = 1
            acText.TextString = Str3.ToString
            acBlkTblRec.AppendEntity(acText)
            acTrans.AddNewlyCreatedDBObject(acText, True)

 Thanks for help.

 

 

 

Valued Mentor
KerryBrown
Posts: 276
Registered: ‎11-29-2008
Message 2 of 4 (219 Views)

Re: new line with vbCrLf is not work?

03-13-2012 02:02 AM in reply to: Amrit.shr

 

I may be wrong, but I didn't think Text used formatting characters.

 

What does the actual string look like when it's added ??

 

Regards

 

//-------------------------------------------------------

Everything will work just as you expect it to, unless your expectations are incorrect.

class keyThumper<T> : Lazy<T>;      another  Swamper

*Expert Elite*
Hallex
Posts: 1,569
Registered: ‎10-08-2008
Message 3 of 4 (215 Views)

Re: new line with vbCrLf is not work?

03-13-2012 03:05 AM in reply to: Amrit.shr

You have to use MText istead

 

~'J'~

_____________________________________
C6309D9E0751D165D0934D0621DFF27919
Contributor
Amrit.shr
Posts: 13
Registered: ‎03-14-2011
Message 4 of 4 (167 Views)

Re: new line with vbCrLf is not work?

03-15-2012 09:54 AM in reply to: Hallex
thanks
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Are You Going To Be @ AU 2014? Feel free to drop by our AU topic post and share your plans, plug a class that you're teaching, or simply check out who else from the community might be in attendance. Ohh and don't forgot to stop by the Autodesk Help | Learn | Collaborate booths in the Exhibit Hall and meet our community team if you get a chance!