none
Vertical Scroll bar appears when setting height for webpart?

    Question

  • The default /Smportal website looks OK.  But I wanted to put the portal webparts in the root website instead.  When I add the webpart, it works fine.  However, there is a really annoying problem where when I set the height so the whole webpart displays, a vertical scroll bar appears on the right side.

    It seems setting overflow: hidden is typically the way to fix this, but I can't seem to find a way to do this in either the master page or invididual pages.

    Has anyone found where to turn this off if moving the webparts into a different site?

    Thanks, Shawn

    Monday, February 20, 2012 4:17 PM

All replies

  • Hi Shawn, Is this on SCSM 2012 or 2010?

    Paresh

    Monday, February 20, 2012 7:00 PM
    Answerer
  • SCSM 2012 RC.  I'm putting it into the main site as a webpart where I get the scroll bar.
    Monday, February 20, 2012 8:31 PM
  • This is happening because the webpart is the container for a Silverlight application and it has a fixed minimum height and minimum width to avoid clipping of content. Unfortunately setting CSS overflow style on the any of the page elements will not change is not supported. 

    If you want to show the Service catalog w/o the scroll bar then try editing the webpart Height property (in appearance section) in the page edit mode. 

    page edit mode- web part properties

    Adjust the height properties as required in the appearance section.

    appearance section


    Thanks, Paresh

    Tuesday, February 21, 2012 10:25 PM
    Answerer
  • Thanks for the response and screenshots!  However, I have specified a height- that is the only way I can get the webpart to become big enough to see the items in the service catalog.  However, it is also when the scroll bar appears- which by the way only scrolls a total of about 1 pixel.  It's not really doing anything useful.  It just feels the need to show up when I do as you have suggested.

    Try going up to the root site (NOT smportal) and adding the service catalog webpart and specify a size.  Even if you choose 660 pixels (the height of the service catalog in SMPORTAL) I believe you'll get a scroll bar as well.  I'm guessing the smportal master page suppresses scroll bars somehow.  However, if I try to use the smportal, I get a datacontrol1 already in use error and the page won't load.

    I can get by with it being there during beta/RC, but when I deploy this for a customer, I'd really like to look as professional as possible- without an extra confusing scroll bar.

    Thanks, Shawn

    Wednesday, February 22, 2012 1:23 PM
  • Hey Shawn,

    I got passed this problem by adding a css property to the pages. You have to use the developer tools included in either IE or chrome to locate the object ID for the silverlight object, but once you do that, it is pretty easy to fix.

    <style type="text/css">
    #ctl00_m_g . * . * ._SilverlightCotrol{
    	display:block;
    }
    </style>
    

    By adding the display:block to the properties of that object, the autogenerated scrollbars will disappear.

    Thanks,
    Michael

    • Proposed as answer by enigma_101888 Wednesday, August 01, 2012 3:27 PM
    Wednesday, August 01, 2012 3:26 PM