Printer Friendly Page

Discussion in 'ASP .Net' started by =?Utf-8?B?SmltIEg=?=, Jul 1, 2005.

  1. I am "printing" data in a label control that was entered via a multi-line
    textbox control. The CRLF are not appearing correctly. Any suggestions?

    Thanks !
    =?Utf-8?B?SmltIEg=?=, Jul 1, 2005
    #1
    1. Advertising

  2. =?Utf-8?B?SmltIEg=?=

    souri challa Guest

    Replace the new line character in the text with a HTML tag. Some thing
    like
    Label1.Text = TextBox1.Text.Replace("\n","<br>")
    HTH,
    -Souri
    souri challa, Jul 1, 2005
    #2
    1. Advertising

  3. Have you tried using System.Environment.NewLine ?



    Juan T. Llibre
    ASP.NET MVP
    http://asp.net.do/foros/
    Foros de ASP.NET en EspaƱol
    Ven, y hablemos de ASP.NET...
    ======================

    "Jim H" <Jim > wrote in message
    news:...
    >I am "printing" data in a label control that was entered via a multi-line
    > textbox control. The CRLF are not appearing correctly. Any suggestions?
    >
    > Thanks !
    Juan T. Llibre, Jul 1, 2005
    #3
  4. =?Utf-8?B?SmltIEg=?=

    Srim Guest

    Try
    this

    Replace with
    str = str.Replace("\r\n","<BR/>")


    lblDescription.Text=Server.HtmlDecode(str);

    I think it will work
    Srim, Jul 1, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. John Klucker

    implementing a Printer Friendly .aspx Page

    John Klucker, Aug 15, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    393
    John Timney \(Microsoft MVP\)
    Aug 15, 2003
  2. =?Utf-8?B?VGlnZ2Vy?=
    Replies:
    2
    Views:
    468
    =?Utf-8?B?SmVyZW15IERhdmlz?=
    Nov 10, 2004
  3. Yog
    Replies:
    0
    Views:
    451
  4. Beavis

    Hotwired Printer Friendly Page

    Beavis, Dec 6, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    288
    Beavis
    Dec 13, 2006
  5. tommy
    Replies:
    2
    Views:
    98
Loading...

Share This Page