This is a migrated thread and some comments may be shown as answers.

How to set ReportViewer auto height

5 Answers 1516 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
xie yufei
Top achievements
Rank 1
xie yufei asked on 05 Jun 2010, 09:13 AM
I created an user control with RadTabStrip and RadMulitipage.It is placed in a Radpane in MasterPage.Content page(.ascx file) loaded dynamiclly into Multipage,Tabstrip is used to be a navigation.I built some reports.the reportviewer has it's own scrollbar,Both X and Y.when the content area is larger than the viewer's original size,it ugly. I want the reportviewer to fullfill the content area,the scorllbar of X is placed on the bottom and the Y bar is placed on the right.

what should i do?

Thanks

5 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 07 Jun 2010, 05:40 PM
Hello xie yufei,

The height of the Web Report Viewer can be set to 100% but you have to set height:100% to the chain of html elements that contain the viewer as well - more info is available in the Web Viewer Introduction help article. Additionally you can remove the DOCTYPE from the page to obtain similar result in different browsers.

Generally it all depends on your scenario. If you just want to make sure the web viewer never renders scrollbars, you can set the ZoomMode property to FullPage.

Sincerely yours,
Steve
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
xie yufei
Top achievements
Rank 1
answered on 08 Jun 2010, 04:19 PM
first ball thanks for your response.

I am testing a report application. my report page is divided into two parts ,the parameter area and the viewer area. my purpose is the reportviewer in the viewer area can fullfill the whole area of viewer area,100% width and 100% height,so the scrollbar can be showed just  on the bottom and the right edge.Now I have resolved the problem by using splitter.I use spilitter to divide my ascx page in two parts.one hold the parameter and the other hold the reportviewer.just like below.
<telerik:RadSplitter runat="server" ID="RadSplitter1" Width="100%" BorderSize="0" 
    BorderStyle="None" PanesBorderSize="0" Height="100%" Orientation="Horizontal">  
    <telerik:RadPane runat="server" ID="RadPane1" Scrolling="None" Height="26px">  
        <div style="width: 100%" id="Top">  
            <div style="float: left">  
                <div style="float: left">  
                    <asp:Label ID="Label1" runat="server" Text="选择查询方式:"></asp:Label></div>  
                <asp:RadioButtonList ID="RadioButtonList1" runat="server" RepeatDirection="Horizontal" 
                    Width="148px">  
                    <asp:ListItem Value="All">汇总</asp:ListItem> 
                    <asp:ListItem Value="Part" Selected="True">分大区</asp:ListItem> 
                </asp:RadioButtonList> 
            </div> 
            <div style="float: right;">  
                <asp:Button ID="btnQuery" runat="server" Text="查  询" OnClick="btnQuery_Click" /> 
                <input id="Button1" type="button" value="关  闭" onclick="closeTab()" /> 
            </div> 
        </div> 
    </telerik:RadPane> 
    <telerik:RadPane runat="server" ID="ViewerPane" Scrolling="None">  
        <uc1:ReportViewer ID="ReportViewer1" runat="server" /> 
    </telerik:RadPane> 
</telerik:RadSplitter> 

but now i have encountered another problem.my english is not good,you can check the attached files to understand what i want to say.
the snapshot 1 is the original loaded page.it looks good.the scrollbar just been placed on the very place,the bottom and the right.then i changed the IE size by dragging the browser's border or double clicking on the header title,the scrollbar is wrong(snapshot 2).then i changed the browser's size more bigger ,a gap appeared(snapshot 3), then when i clicked one button (next page or refresh ,any one on the toolbar),the scrollbar become good again(snapshot 4).

so how can i control the browser resize event to ensure the scrollbar's acurate position?

I have found another problem in my test application too.first i use the report's integrated parameter definition.in the preview mode ,it looks good(snapshot 5),but when i run the page,the parameter's text is wrapped(look the snap6).i found if use english words it is good and  be wrapped when use chinese words.now i have to define my own parameters area .

I hope you can understand what i said.sorry for my bad expression in English.

thanks !
0
Steve
Telerik team
answered on 09 Jun 2010, 05:06 PM
Hi xie yufei,

Such case has not been foreseen and we're not sure if it can work properly in it, but try forcing the viewer to repaint itself in the pane. To do that you should hook up to the OnClientResized event and invoke the AdjustReportAreaHeight method e.g.:

<script type="text/javascript">
         function resizeViewer()
        {
            <%=ReportViewer1.ClientID %>.AdjustReportAreaHeight();
        }
    </script>
.......
<telerik:RadPane runat="server" ID="ViewerPane" Scrolling="None" OnclientResized="resizeViewer">  
        <uc1:ReportViewer ID="ReportViewer1" runat="server" />
    </telerik:RadPane>
.....

As for the wrapping of the report parameter label - we were able to reproduce this, but we are uncertain why it happens and would need to investigate this further. For the time being please set spaces between the hieroglyphs, which somehow stretches the label in the browser (see attached screenshot)

Regards,
Steve
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Sergio
Top achievements
Rank 1
answered on 13 May 2013, 04:33 PM
Greetings,

I have a problem with the rendering of the Telerik Reporting Web Viewer, Kind of Similar.

The reportviewer I am describing renders in a SharePoint 2010 Webpart and it work correctly.

The only issue is that the report viewer has a bouncing effect from bottom up, when the page is loading. In other words, the report viewer first shows on the button and then goes to the top,, to its original design position (In design view)

This behavior also happen when there is no custom parameters. Meaning that the report viewer is the only element in the web part. (The web part again displays first in the bottom, then changes its position to the top)

The larger the size of the Report Viewer Height property the large the bounces occurrence.

How could I prevent this odd behavior

Please let me know and Thanks
0
Stef
Telerik team
answered on 16 May 2013, 03:55 PM
Hi Sergio,

Please check whether outer styles do not apply over the ReportViewer control and thus cause the bouncing effect. Also test whether the issue is reproducible when you replace the report viewer with other control on the same place.

If you need further help, send us a runnable sample project illustrating the issue in a support ticket or post your code here with more details how to reproduce the described.

Kind regards,
Stef
the Telerik team

Have you tried the new visualization options in Telerik Reporting Q1 2013? You can get them from your account.

Tags
General Discussions
Asked by
xie yufei
Top achievements
Rank 1
Answers by
Steve
Telerik team
xie yufei
Top achievements
Rank 1
Sergio
Top achievements
Rank 1
Stef
Telerik team
Share this question
or