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

ReportViewer failed on IE and Firefox 64bits

5 Answers 51 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Rome Marti
Top achievements
Rank 1
Rome Marti asked on 17 Oct 2012, 06:27 AM
Hello,

I have implemented a ReportViewer in a page but I have issues to make the "PrintReport function" works properly on IE9 and Firefox.
I load the component with a ReportBook who can contains severals pdf files.
Then the component call : printReport(); (the component is hidden, it is just used to print the report)

<td style="display: none">

<telerik:ReportViewer ID="ReportViewer1" runat="server" Height="0px" Width="0px"

Visible="True">

</telerik:ReportViewer>

<script type="text/javascript">

<%=ReportViewer1.ClientID %>.PrintReport();

</script>

</td>


In this case, the brower ask me just to download the file ReportBook.pdf (containing the pdfs...) instead of showing me the Print screen.
The issue appear on the IE9 64bits edition, but It s working properly on IE9 32 bits...
What could explain the difference of behavior of the component when I used à 64 bits version of a browser over a 32 bits ?
I am using Telerik Reporting Q1 2012 (v 6.0.12.215).

Thanks for your insight !

Regards,

5 Answers, 1 is accepted

Sort by
0
Elian
Telerik team
answered on 22 Oct 2012, 09:01 AM
Hello Rome,

Our printing functionality depends on the Adobe PDF Reader browser add-on. If it cannot be found (which is the case with the IE 64bit), then the viewer falls back  to saving the document as a PDF.

For more information on the subject please visit our help article True Print.
 
Regards,
Elian
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Steve
Top achievements
Rank 1
answered on 21 Feb 2013, 10:33 PM
Hi,
My question is different. I am new to Telerik report. I have my report viewer in my aspx page. The CSS has been messed up in IE 7.0. But, its working fine in Firefox, Chrome, Opera. Appreciate your help..
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="MNT_CashManagementBatchAURPT.aspx.vb"
    Inherits="WLAdmin.CashManagementBatchAURPT" MasterPageFile="../../Admin.Master"
    Description="12.0.31.0;WebLinks" %>
 
<%@ Register Assembly="Telerik.ReportViewer.WebForms, Version=6.2.13.110, Culture=neutral, PublicKeyToken=a9d7983dfcc261be"
    Namespace="Telerik.ReportViewer.WebForms" TagPrefix="telerik" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register Assembly="ActiveReports.Web, Version=6.2.3681.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff"
    Namespace="DataDynamics.ActiveReports.Web" TagPrefix="ActiveReportsWeb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">
        .style3
        {
            width100%;
        }
        .style4
        {
            width119px;
        }
        .style5
        {
            width122px;
        }
        .style6
        {
        }
        .style7
        {
            width175px;
        }
        .style8
        {
            width236px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
        <script type="text/javascript">
            function OnKeyPressSerialText(sender, eventArgs) {
                var char = eventArgs.get_keyCharacter();
                //will allow just letters 
                var exp = /[^a-zA-Z]/g;
                if (exp.test(char)) {
                    eventArgs.set_cancel(true);
                }
            }
            // To make the items in the FieldName by-default "Checked"//
            function ChkFieldName(sender) {
                var combo = sender;
                var items = combo.get_items();
                var itemCount = items.get_count()
                for (var counter = 0; counter < itemCount; counter++) {
                    var item = items.getItem(counter);
                    item.set_checked(true)
                }
            }
            function GetReportName(sender, blnShowName) {
                var hdnRptID = $get("<%= hdnReportID.ClientID %>");
                var hdnRptName = $get("<%= hdnReportName.ClientID %>");
                var initText = '';
                var headText = 'Save New Report';
                var callBackFn = function (args) {
                    if (args) {
                        hdnRptName.value = args.substring(0, 50);
                        __doPostBack(sender.id.replace(/_/gi, '$'), '');
                    }
                    else {
                        return false;
                    }
                }
                if (blnShowName) {
                    initText = hdnRptName.value;
                    headText = 'Save Report'
                } else {
                    hdnRptID.value = '';
                }
                var prompt = radprompt('What would you like to name the report?', callBackFn, 300, 100, null, headText, initText);
                prompt.set_behaviors(Telerik.Web.UI.WindowBehaviors.Close);
                prompt.moveTo(315, 150);
            }
        </script>
    </telerik:RadScriptBlock>
    <div align="left">
        <br />
        <br />
        <table>
            <tr>
                <td align="left" class="style8">
                    <asp:RegularExpressionValidator ID="emailValidator" runat="server" Display="Dynamic"
                        ErrorMessage="Please, enter valid e-mail address." ValidationExpression="^[\w\.\-]+@[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]{1,})*(\.[a-zA-Z]{2,3}){1,2}$"
                        ControlToValidate="txtEmail">
                    </asp:RegularExpressionValidator>
                </td>
            </tr>
        </table>
        <asp:Label ID="lblReportTitle" runat="server" Font-Bold="True" Font-Names="Arial"
            Text="Cash Management Batch Maintenance Report" Font-Size="10pt"></asp:Label>
        <br />
        <table class="style3">
            <tr>
                <td align="right" class="style4">
                    <asp:Label ID="Label1" runat="server" Font-Names="Arial" Font-Size="10pt" Text="Start Date:"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadDatePicker ID="rdpStartDate" runat="server">
                        <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                        </Calendar>
                        <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                        <DateInput DisplayDateFormat="M/d/yyyy" DateFormat="M/d/yyyy">
                        </DateInput>
                    </telerik:RadDatePicker>
                </td>
                <td align="left" class="style6" colspan="2">
                    <asp:Label ID="lblErrorText" runat="server" Font-Names="Arial" Font-Size="10pt" ForeColor="#CC3300"
                        Visible="False"></asp:Label>
                </td>
                <%--                <td align="left">
                    &nbsp;
                </td>--%>
                <td align="right" class="style4">
                    <asp:Label ID="lblUserName" runat="server" Text="UserName:" Visible="false"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadTextBox ID="txtUserName" runat="server" Visible="false">
                    </telerik:RadTextBox>
                </td>
                <td align="right" class="style4">
                    <asp:Label ID="lblName" runat="server" Text="Name:" Visible="false"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadTextBox ID="txtName" runat="server" SelectionOnFocus="SelectAll" Visible="false">
                        <ClientEvents OnKeyPress="OnKeyPressSerialText" />
                    </telerik:RadTextBox>
                </td>
            </tr>
            <tr>
                <td align="right" class="style4">
                    <asp:Label ID="Label2" runat="server" Font-Names="Arial" Font-Size="10pt" Text="End Date:"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadDatePicker ID="rdpEndDate" runat="server">
                        <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                        </Calendar>
                        <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                        <DateInput DisplayDateFormat="M/d/yyyy" DateFormat="M/d/yyyy">
                        </DateInput>
                    </telerik:RadDatePicker>
                </td>
                <td class="style7">
                    &nbsp;
                </td>
                <td class="style8">
                    &nbsp;
                </td>
                <td align="right" class="style4">
                    <asp:Label ID="lblEmail" runat="server" Text="Email:" Visible="false"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadTextBox ID="txtEmail" runat="server" Visible="false">
                    </telerik:RadTextBox>
                </td>
                <td align="right" class="style4">
                    <asp:Label ID="lblAction" runat="server" Text="Action:" Visible="false"></asp:Label>
                </td>
                <td align="left">
                    <telerik:RadComboBox ID="rcbAction" runat="server" Width="145px" Visible="false">
                    </telerik:RadComboBox>
                </td>
                <td>
                    <asp:HiddenField runat="server" ID="hdnReportName" Value="" EnableViewState="true" />
                </td>
            </tr>
            <tr>
                <td align="right" colspan="5">
                    <asp:Label ID="lblFieldName" runat="server" Text="Field Name:" Visible="false"></asp:Label>
                </td>
                <td align="left" class="style5">
                    <telerik:RadComboBox ID="rcbFieldName" runat="server" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"
                        Visible="false" CheckedItemsTexts="DisplayAllInInput" Height="200px">
                    </telerik:RadComboBox>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:CheckBox ID="ChkAction" runat="server" AutoPostBack="True" Font-Names="Arial"
                        Font-Size="10pt" Text="Action" />
                </td>
                <td>
                    <asp:CheckBox ID="ChkUserInfo" runat="server" AutoPostBack="True" Font-Names="Arial"
                        Font-Size="10pt" Text="UserInformation" />
                </td>
                <td>
                    <asp:CheckBox ID="ChkFieldName" runat="server" AutoPostBack="True" Font-Names="Arial"
                        Font-Size="10pt" Text="FieldName" />
                </td>
            </tr>
            <tr>
                <td class="style4">
                    &nbsp;
                </td>
                <td class="style5">
                    <asp:Button ID="btnGetReport" runat="server" Text="Get Report" />
                </td>
                <td class="style4">
                    <asp:Button runat="server" ID="cmdSaveNewReport" Text="Save New Report" OnClientClick="GetReportName(this,false); return false;" />
                </td>
                <td class="style8">
                    <asp:Button runat="server" ID="cmdSaveReport" Text='Save ""' OnClientClick="GetReportName(this,true); return false;"
                        Visible="false" />
                </td>
                <td>
                    <asp:HiddenField runat="server" ID="hdnReportID" Value="" EnableViewState="true" />
                </td>
            </tr>
        </table>
        <br />
        <%--        <ActiveReportsWeb:WebViewer ID="wbvCashManageBatchRPT" runat="server" Height="378px"
            Visible="False" Width="950px">
        </ActiveReportsWeb:WebViewer>--%>
        <telerik:ReportViewer ID="ReportViewer" runat="server" Visible="false" Width="700px"></telerik:ReportViewer>
        <asp:Label ID="ReportMessage" runat="server" Visible="false" Font-Bold="True" ForeColor="Red"></asp:Label>
    </div>
</asp:Content>
0
Hadib Ahmabi
Top achievements
Rank 1
answered on 26 Feb 2013, 10:21 AM
This sounds like some style collision. Try removing / renaming the styles that affect the webpage and see if anything changes. Also if you remove the viewer does the page look correct?
0
Steve
Top achievements
Rank 1
answered on 26 Feb 2013, 08:27 PM
Thank you for the response...I have tried that by commenting all the in-line styles and just having the controls along with the report viewer, but it didn't worked. Just to test, I have commented the telerik report viewer as well and everything is good in all the browsers. Now, I have un-commented the telerik report viewer and the styles are messed up only in IE 7.0,8.0. It's well aligned in the other browsers like Opera, Firefox, Chrome etc...... Couldn't figure it out........
0
Hadib Ahmabi
Top achievements
Rank 1
answered on 01 Mar 2013, 11:01 AM
Is there any difference when the viewer is visible?

Why are you using the viewer anyway?
Just use the ReportProcessor to export the reports programmatically on button click. 
Tags
General Discussions
Asked by
Rome Marti
Top achievements
Rank 1
Answers by
Elian
Telerik team
Steve
Top achievements
Rank 1
Hadib Ahmabi
Top achievements
Rank 1
Share this question
or