Resizing labels so they fit on one line

Discussion in 'ASP .Net Web Controls' started by Jim Bancroft, Jul 18, 2005.

  1. Jim Bancroft

    Jim Bancroft Guest

    Hi everyone,

    I'm using a Web control label to display some text on-screen. I'd like
    to dynamically set the width property during the page load, so that the
    label is wide enough to accomodate the text I assign to it, without
    wrapping.

    Is there a reccomended way to do this? I've been fiddling around with stuff
    like multiplying the text length by the font size, but so far it hasn't
    worked...thanks!
    Jim Bancroft, Jul 18, 2005
    #1
    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. vertigo
    Replies:
    10
    Views:
    706
    Not in my trousers
    Jul 6, 2003
  2. ghiro
    Replies:
    20
    Views:
    1,398
  3. Noozer
    Replies:
    22
    Views:
    29,788
    Noozer
    Jan 17, 2005
  4. Piet
    Replies:
    0
    Views:
    506
  5. Jean-Sébastien

    resizing html to fit in dispplayed window

    Jean-Sébastien, Apr 22, 2007, in forum: Javascript
    Replies:
    2
    Views:
    90
Loading...

Share This Page