Line wrapping with WebForm Label

Discussion in 'ASP .Net' started by =?Utf-8?B?bWc=?=, Jan 19, 2004.

  1. I set the width of a WebForm Label but do not get line wrapping (see below). What can I do to get line wrapping

    WebForm1.asp

    <asp:Labe
    id="Label1"
    style="Z-INDEX: 101; LEFT: 40px; POSITION: absolute; TOP: 48px
    runat="server" Width="150px" Height="64px"></asp:Label


    WebForm1.aspx.c

    Label1.Text = "MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM"
     
    =?Utf-8?B?bWc=?=, Jan 19, 2004
    #1
    1. Advertising

  2. Without a space, the label text won't wrap. You may need to resort to a subtstring in order insert a space that the control is able to use for wrapping

    ----- mg wrote: ----

    I set the width of a WebForm Label but do not get line wrapping (see below). What can I do to get line wrapping

    WebForm1.asp

    <asp:Labe
    id="Label1"
    style="Z-INDEX: 101; LEFT: 40px; POSITION: absolute; TOP: 48px
    runat="server" Width="150px" Height="64px"></asp:Label



    WebForm1.aspx.c

    Label1.Text = "MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM"
     
    =?Utf-8?B?QmFycnkgRm9ycmVzdA==?=, Jan 19, 2004
    #2
    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. Mike Casey
    Replies:
    7
    Views:
    3,952
    Scott M.
    Dec 19, 2003
  2. =?Utf-8?B?bWc=?=

    Line wrap - WebForm Label

    =?Utf-8?B?bWc=?=, Jan 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    2,416
    Andy Mortimer [MS]
    Jan 19, 2004
  3. rodchar

    label wrapping

    rodchar, Dec 3, 2007, in forum: ASP .Net
    Replies:
    2
    Views:
    378
    rodchar
    Dec 3, 2007
  4. KJ

    asp:label not wrapping

    KJ, Jun 24, 2004, in forum: ASP .Net Web Controls
    Replies:
    1
    Views:
    137
    Scott M.
    Jun 24, 2004
  5. Knut Krueger
    Replies:
    8
    Views:
    282
    Knut Krueger
    Aug 20, 2013
Loading...

Share This Page