none
ReportViewer Height RRS feed

  • Question

  •   

    Hi,

    I found this forum to help me about ReportViewer Height. 
    http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=260300&SiteID=1

    I tried the JavaScript to help Remove the scroll bars, it works fine, thank you.

    But I'm trying to use PromptAreaCollapsed () but I can't figure out how to use it.

    <script language="JavaScript" type="text/JavaScript">

    window.onload=function RemoveScrollbars()

    {

    var viewer = document.getElementById("<%=m_ReportViewer.ClientID %>");

    viewer.PreRender = PreRenderResize()

    }

    function PreRenderResize()

    {

    var viewer = document.getElementById("<%=m_ReportViewer.ClientID %>");

    var htmlheight = document.documentElement.clientHeight;

    if( viewer.PromptAreaCollapsed() == true )

    {

            viewer.style.height = (htmlheight - 129) + "px";
    }
    else

    {

    viewer.style.height = (htmlheight - 241) + "px";

    }

    }

    </script>

    Thanks for your help.

    Freedon

    • Edited by Simon Pesant Friday, August 8, 2008 1:39 PM missing brackets
    Friday, August 8, 2008 1:21 PM