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

Disable RadAjaxPanel For LinkButton

1 Answer 220 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Muhammad
Top achievements
Rank 1
Muhammad asked on 22 Jan 2011, 09:08 PM
Hi,

I am using RadAjaxPanel and my girdview is under that panel. I have one template and under that template I have one button for report which opening a new report in a new page but the problem is that under ajax panel it doesn't work and if I remove my the ajax panel it works fine and open a new report in a new window. If this problem is with the response.write then how can I disable my ajax request for opening a report in a new window.  Because I don't want to completely remove ajaxpanel or if you can provide some solution without disabling ajax request. 


<telerik:RadAjaxLoadingPanel ID="alpProductionSechduleMain" runat="server" Height="75px"
    MinDisplayTime="5" Width="75px">
    <asp:Image ID="Image1" runat="server" AlternateText="Loading..." ImageUrl="~/Portals/0/Images/LoadingAjax.gif" />
</telerik:RadAjaxLoadingPanel>
<telerik:RadAjaxPanel ID="rapPSMain" RequestQueueSize="5" runat="server" Width="100%" 
    OnAjaxRequest="rapPSMain_AjaxRequest" EnableOutsideScripts="True" HorizontalAlign="NotSet" 
    ScrollBars="None" LoadingPanelID="alpProductionSechduleMain" ><asp:GridView ID="gvJobs" runat="server" Width="100%" CellPadding="2" AutoGenerateColumns="False"
        CssClass="gridviewSpacing gvJobs" AllowPaging="true">
        <Columns>
            <asp:TemplateField>
                <ItemTemplate>
                    <asp:LinkButton ID="lnkbtnEditJob" runat="server" CommandArgument='<%# Eval("JobKey")%>'
                        OnClick="lnkbtnEditJob_Click">edit</asp:LinkButton>
                    <asp:LinkButton ID="lnkbtnPrintJob" runat="server" CommandArgument='<%# Eval("JobKey")%>' OnClientClick="OpenReport(this);" >print</asp:LinkButton>
                </ItemTemplate>
            </asp:TemplateField></Columns></asp:GridView></telerik:RadAjaxPanel>Protected Sub rapPSMain_AjaxRequest(ByVal sender As Object, ByVal e As Telerik.Web.UI.AjaxRequestEventArgs)        Response.Clear()
        Response.AddHeader("Content-Disposition", "attachment;filename=" & sFilename & ".htm")
        Response.ContentType = "text/html"


Protected Sub rapPSMain_AjaxRequest(ByVal sender As Object, ByVal e As Telerik.Web.UI.AjaxRequestEventArgs)
        Response.Clear()
        Response.AddHeader("Content-Disposition", "attachment;filename=" & sFilename & ".htm")
        Response.ContentType = "text/html"
        Dim eEncoding As Encoding = Encoding.GetEncoding("Windows-1252")
        Dim eUnicode As Encoding = Encoding.Unicode
        Dim byUnicodeBytes As Byte() = eUnicode.GetBytes(sData)
        Dim byEncodedBytes As Byte() = Encoding.Convert(eUnicode, eEncoding, byUnicodeBytes)
        Response.BinaryWrite(byEncodedBytes)
        Response.Flush()
        Response.End()
    End Sub













1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 24 Jan 2011, 09:20 AM
Hello Muhammad,

Please examine the following help article and see if it helps to disable AJAX for the LinkButton:
http://www.telerik.com/help/aspnet-ajax/ajxexclude.html

Greetings,
Pavlina
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Ajax
Asked by
Muhammad
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Share this question
or