I have followed all the posts I can find, looked at the Demo's online and tried some of them synergetically. Here is where I am at.
I have a RadGrid "Prometheus" running in a DNN module on the 3.5 framework using the OnNeedDataSource event.
The grid is using AJAX, a RadLoadingPanel, and a RadAjaxManager to handle all the AJAX events.
I am also using the RadGrid Reporting Functionalities but not within the Pager - they are image buttons on the page.
I included the two panels, one asp:panel one telerik:RadAjaxPanel and set the asp:panel's default button but that doesn't seem to work for me. So here is my code:
By setting the javascript args this way, I know that the grid will behavior will exhibit AJAX functionality.
What I would like to do is use the JavaScript to disable the AJAX and produce the needed result. In this scenario if I had only one button (Excel, Pdf, or Word) everything would work fine and I wouldn't be writing this post. So here is the crux of the issue.
No matter which button I press first - the page will attempt to export that type.
so if I click excel it works. Then I decide to click pdf - it exports excel again.
If I simply change the sorting on the radGrid, then click pdf it works normally again. Then I decide to export Word. It once again attempts to export pdf.
And so on...
Obviously, there is something that is storing the export type here... I am thinking that its somewhere in the DOM. Where is it stored, and can I reset or clear it using a JavaScript function?
Thanks In Advance!
John
I have a RadGrid "Prometheus" running in a DNN module on the 3.5 framework using the OnNeedDataSource event.
The grid is using AJAX, a RadLoadingPanel, and a RadAjaxManager to handle all the AJAX events.
I am also using the RadGrid Reporting Functionalities but not within the Pager - they are image buttons on the page.
I included the two panels, one asp:panel one telerik:RadAjaxPanel and set the asp:panel's default button but that doesn't seem to work for me. So here is my code:
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> |
<script type="text/javascript"> |
function OnRequestStart(sender, args) |
{ |
args.set_enableAjax(true); |
} |
function OnResponseEnd(sender, args) |
{ |
args.set_enableAjax(false); |
} |
</script> |
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> |
<AjaxSettings> |
<telerik:AjaxSetting AjaxControlID="radGrid"> |
<UpdatedControls> |
<telerik:AjaxUpdatedControl ControlID="radGrid" LoadingPanelID="alpGrid" /> |
</UpdatedControls> |
</telerik:AjaxSetting> |
</AjaxSettings> |
<ClientEvents OnRequestStart="OnRequestStart" OnResponseEnd="OnResponseEnd" /> |
</telerik:RadAjaxManager> |
<telerik:RadAjaxPanel ID="radPanel" runat="server" ClientEvents-OnRequestStart="OnResponseEnd" ClientEvents-OnResponseEnd="OnRequestStart"> |
<asp:ImageButton ID="cmdExportToExcel" Style="cursor: pointer;" ImageUrl="~/DesktopModules/Slideshow/Images/excel-tips-tricks.png" |
AlternateText="Export to Excel" runat="server" |
onclick="cmdExportToExcel_Click"></asp:ImageButton> |
<asp:ImageButton ID="cmdExportToWord" Style="cursor: pointer;" ImageUrl="~/DesktopModules/Slideshow/Images/word-tips-tricks.png" |
AlternateText="Export to Word" runat="server" |
onclick="cmdExportToWord_Click"></asp:ImageButton> |
<asp:ImageButton ID="cmdExportToPdf" Style="cursor: pointer;" ImageUrl="~/DesktopModules/Slideshow/Images/pdf_icon.gif" Width="35px" |
AlternateText="Export to Pdf" runat="server" |
onclick="cmdExportToPdf_Click"></asp:ImageButton> |
<asp:Label ID="lblExport" runat="server" /> |
</telerik:RadAjaxPanel> |
<telerik:RadAjaxLoadingPanel ID="alpGrid" runat="server" Transparency="30"> |
<asp:Image ID="Image1" ImageUrl="~/DesktopModules/Slideshow/images/loading.gif" AlternateText="Loading. Please wait..." BorderWidth="0px" runat="server"></asp:Image> |
</telerik:RadAjaxLoadingPanel> |
By setting the javascript args this way, I know that the grid will behavior will exhibit AJAX functionality.
What I would like to do is use the JavaScript to disable the AJAX and produce the needed result. In this scenario if I had only one button (Excel, Pdf, or Word) everything would work fine and I wouldn't be writing this post. So here is the crux of the issue.
No matter which button I press first - the page will attempt to export that type.
so if I click excel it works. Then I decide to click pdf - it exports excel again.
If I simply change the sorting on the radGrid, then click pdf it works normally again. Then I decide to export Word. It once again attempts to export pdf.
And so on...
Obviously, there is something that is storing the export type here... I am thinking that its somewhere in the DOM. Where is it stored, and can I reset or clear it using a JavaScript function?
Thanks In Advance!
John