Cannot display full report contents (usably) in ASP.NET page

theBigDummy
theBigDummy used Ask the Experts™
on
Hello, I finally had to join Experts Exchange to try to solve this problem.  It is utterly confounding me and everywhere else I've looked, I get the same stale solutions.  Ultimately, all I am trying to do is display detail report data with many columns and many rows (too wide and too high for the window) in both IE and Firefox, with appropriate scrolling so that the report is usable.

Ideally, I would like to use the ReportViewer control, with AsyncRendering set to TRUE, and the height set to 100% of the container, and that's what I'm currently attempting to do (the code is below).  Under this scenario, I need to have our company logo at the top of the window, and I want a footer at the bottom, with the report viewer filling up the space in between.  Then the ReportViewer scrollbars will suffice.  The problem is that if I attempt to have the ReportViewer display at 100% height within its container, I get no records to display.

I am also open to displaying the entire report with AsyncRendering set to FALSE, thereby letting the footer drop out of the window to the bottom of the report.  However, while I do get a horizontal scrollbar in IE6 using this approach, it does not resize itself to the report contents.  Firefox works finie, but nothing I try or that I've found Googling works in IE.  All data to the right of the window display is lost.

By the way, I cannot use the GridView, ReportViewer, or any other control's horizontal scrollbar if that control extends beyond the bottom of the window.  Most users aren't clever enough to go to the bottom of the report to look for the scrollbar, and in any event, that's a crummy way to get to the right-most columns of the report if you then have to use the vertical bar to get back up to the rows you want.

Thanks in advance for any support you can give me.  I'm baffled that with all the development I've done on this project, I'm now stuck with an unusable product because of something so simple as displaying all my data.  The fact that I'm using ASP.NET, and it's only IE where this is a problem, is especially vexing.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default3.aspx.cs" Inherits="Default3" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/strict.dtd">
<%@ Register Src="~/SOx Site Contents.ascx" TagPrefix="SSC" TagName="SOxSiteContents" %>
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
 
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Master Page</title>
    <meta name="GENERATOR" content="Adobe PageMill 2.0 Win" />
 
    <style type="text/css">
        html,body,form { margin:0px; padding:0px; height:100%; width:100%; border:none; max-height:100% }
        #top
        {
            width: 100%;
            height: 35px;
            position: absolute;
            top: 0px;
            left: 0px;
        }
        #middle
        {
            width: 100%;
            position: absolute;
            top: 125px;
            left: 0px;
            bottom: 110px;
        }
        #bottom
        {
            width: 100%;
            height: 110px;
            position: absolute;
            bottom: 0px;
            left: 0px;
        }
        #bottom
        {
            color: inherit;
            background-color: #cccccc;
        }
        .footer
        {
            font-family:Arial;
            font-size:smaller;
        }
    </style>
</head>
<body>
    <form id="frmMaster" runat="server">
 
        <div id="top">
            <table id="tblHeader" border="0" cellspacing="0" cellpadding="0" style="font-family:Arial; table-layout:fixed; width:100%; height:125px">
                <tr>
                    <td width="200" valign="bottom" style="height:90px; width:200px">
	                    <div><img alt="Company Logo"  border="0" src="images/logo90wb.gif" width="200" height="90" /></div>				
                    </td>
                    <td align="right" valign="bottom">
	                    <div><img alt="IT" border="0" src="images/MyCompany_it_banner.jpg" width="560" height="90" /></div>				
                    </td>
                </tr>
                <tr>
                    <td valign="middle" align="left" bgcolor="#000080" colspan="2" style="width:100%; height:35px; color:White">IT Q&amp;C Common Metrics &amp; Reporting</td>
                </tr>
            </table>
        </div>
        
        <div id="middle">
            <SSC:SOxSiteContents id="SOxSiteContents1" runat="server" /><br />
                <rsweb:ReportViewer ID="ReportSA" runat="server" Font-Names="Verdana" Width="100%" Height="100%" Font-Size="8pt" SizeToReportContent="True" AsyncRendering="True">
                    <LocalReport ReportPath="SelfTests.rdlc" EnableHyperlinks="True">
                        <DataSources><rsweb:ReportDataSource DataSourceId="SADataSource" Name="CMTOOL_Tests_SA_vGRC___Control_Tests___Self" /></DataSources>
                    </LocalReport>
                </rsweb:ReportViewer>
            <asp:SqlDataSource ID="SADataSource" runat="server" 
                ConnectionString="<%$ ConnectionStrings:CMTOOL %>"        
                SelectCommand="SELECT TOP (100) PERCENT [VP], [Level 2], [eSigner], [Manager], [Process Title], [Tier Number], [Control Title], [Quarter], [Control Test Item], [SOW], [Status], [ASOFDATE], [CONTROLID], [CONTROLTESTITEMID], [extractDate] FROM [vGRC - Controls and Tests - by Quarter] ORDER BY [Process Title], [Control Title], [Quarter]">
            </asp:SqlDataSource>
        </div>
        
        <div id="bottom">
            <table id="tblFooter" style="width:100%" cellspacing="0" cellpadding="1">
                <tr bgcolor="#003399">
                    <td align="left" class="footer" valign="middle"><font color="#FFFFFF">version 2.2</font></td>
                    <td align="right" class="footer" valign="middle"><font color="#FFFFFF">Last Update: Oct 19, 2009</font></td>
                </tr>
                <tr>
                    <td align="left" valign="top"><font size="1" face="Verdana, Arial, Helvetica, sans-serif">MYCOMPANY is a trademark of MyCompany Management Company.<br />
                    Copyright &copy; 2009 MyCompany. All rights reserved. </font></td>
                </tr>
            </table>
        </div>
        
    </form>
</body>
</html>

Open in new window

Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Commented:
In these kind of situations I prefer rendering the report to HTML and show it in explorer window...

Author

Commented:
Ah, that sounds interesting.  But I've never done any straight HTML coding.  Any suggestions on where I might start?

Commented:
no need to do any html Coding..

What u ave to do is.. while showing content.. Render the report as HTML localreport.render function does everything ..



Check this link from MSDN

http://msdn.microsoft.com/en-us/library/ms251839%28VS.80%29.aspx


What is important is to get an deviceInfo.xml .. that xml file is used for setting render target properties..


CompTIA Security+

Learn the essential functions of CompTIA Security+, which establishes the core knowledge required of any cybersecurity role and leads professionals into intermediate-level cybersecurity jobs.

Author

Commented:

Sorry, I looked through that MSDN link, and I don't see anything on rendering as HTML.  And when I search the web for anything on the subject, I'm getting nothing of any help.

I cannot believe that something so straight-forward as this doesn't have a simple solution.  I am only printing a table, which has more width and height than the display, to Internet Explorer 6 using an ASP.NET page.  My only requirements are that I need a header at the top of the screen, and I cannot have the scrollbars disappear offscreen.  It works in other browsers but not IE?  

I'll be happy with any solution at all as long as I can have a header at the top of the screen.  I'll use a gridview or a reportviewer, anything...
Commented:

Author

Commented:
Ok, thanks for the help, I have a solution.  The problem is that IE seems to size the horizontal toolbar based on the topmost element of the form.  So since my header was sized to 100% width in its own div container, IE refused to recognize that there was content beneath it that was wider than the display.  Other browsers do not seem to have that problem.  So I guess IE6 blows.

Author

Commented:
Hi non-zero. I just noticed your most recent post.  I'll check it and see if that affords me a better solution.  I don't especially like my work around, because I'd prefer my header (which includes links and filters) remain at the top of the screen instead of scrolling off.  But if I have to live with that I will, because the scrollbars are the crucial elements.

Thanks!

Commented:
thank you Learned One

Commented:
thank you Learned One

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial