force horizontal scrollbar display on div

Discussion in 'ASP .Net' started by =?Utf-8?B?ZGhucml2ZXJzaWRl?=, Sep 2, 2005.

  1. Hi guys

    I'm using a div to create a list with ajax stuff. At the moment, the div
    shows a scrollbar if the content is larger than the div.

    The problem is that if it isnt, the scrollbar disappears and all my content
    resizes, which obviously I don't want.

    I know I can use overflow: auto on the div, but that shows a horizontal
    scrollbar as well, and I don't need that - and because it's obvious I don't
    need it - it looks daft.

    Question - how can I get the vertical scrollbar to stay (and be grayed out
    if necessary) but NOT have the horizontal scrollbar?

    Any help appreciated, and I'm open to suggestions that don't involve a div!

    Cheers


    Dan
    =?Utf-8?B?ZGhucml2ZXJzaWRl?=, Sep 2, 2005
    #1
    1. Advertising

  2. Hi

    See page source for
    http://support.microsoft.com/default.aspx?scid=kb;en-us;274188
    Works with IE but not with Firefox :(

    --
    Milosz Skalecki
    MCP, MCAD


    "dhnriverside" wrote:

    > Hi guys
    >
    > I'm using a div to create a list with ajax stuff. At the moment, the div
    > shows a scrollbar if the content is larger than the div.
    >
    > The problem is that if it isnt, the scrollbar disappears and all my content
    > resizes, which obviously I don't want.
    >
    > I know I can use overflow: auto on the div, but that shows a horizontal
    > scrollbar as well, and I don't need that - and because it's obvious I don't
    > need it - it looks daft.
    >
    > Question - how can I get the vertical scrollbar to stay (and be grayed out
    > if necessary) but NOT have the horizontal scrollbar?
    >
    > Any help appreciated, and I'm open to suggestions that don't involve a div!
    >
    > Cheers
    >
    >
    > Dan
    =?Utf-8?B?TWlsb3N6IFNrYWxlY2tp?=, Sep 2, 2005
    #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. Marco Liedekerken

    Panel with horizontal scrollbar

    Marco Liedekerken, Jun 26, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    5,918
    Rajesh.V
    Jun 26, 2003
  2. Jeremy Chapman
    Replies:
    1
    Views:
    883
    szabelin
    Aug 15, 2003
  3. Lundy
    Replies:
    0
    Views:
    669
    Lundy
    Oct 6, 2004
  4. Bill Todd

    How get horizontal scrollbar to display?

    Bill Todd, Mar 7, 2004, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    140
    Bill Todd
    Mar 7, 2004
  5. Replies:
    7
    Views:
    114
Loading...

Share This Page