Hello I've the following problem:
I've a page, Default.aspx, which contains a placeholder for a dynamically loaded UserControl (#UC1). UC1 cotains a fixed programmed UserControl UC1A which contains a RadGrid with a LinkButton defined in the CommandItemTemplate. When clicking on the linkbutton I expect the OnRequestStarted will be called but the alert message in the script function never appears. It seems the postback is being cancelled.
So masterpage:
UC1A contains:
I've a page, Default.aspx, which contains a placeholder for a dynamically loaded UserControl (#UC1). UC1 cotains a fixed programmed UserControl UC1A which contains a RadGrid with a LinkButton defined in the CommandItemTemplate. When clicking on the linkbutton I expect the OnRequestStarted will be called but the alert message in the script function never appears. It seems the postback is being cancelled.
So masterpage:
... <head> .. <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server"> <script type="text/javascript"> function onRequestStart(sender, args) { alert(args.get_eventTarget()); if (args.get_eventTarget().indexOf("ExportToExcelButton") >= 0 || args.get_eventTarget().indexOf("ExportToCsvButton") >= 0 || args.get_eventTarget().indexOf("ExportToPdfButton") >= 0) { args.set_enableAjax(false); } } </script> </telerik:RadCodeBlock> <asp:ContentPlaceHolder ID="HeadContent" runat="server"> </asp:ContentPlaceHolder> </head> <body> <form runat="server"> <telerik:RadScriptManager ID="RadScriptManager1" runat="server" /> <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> <ClientEvents OnRequestStart="onRequestStart" /> </telerik:RadAjaxManager> .... </form> .... </body>UC1A contains:
<telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> <AjaxSettings> <telerik:AjaxSetting AjaxControlID="rgRelation"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="rgRelation" /> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings> </telerik:RadAjaxManagerProxy> asp:Label ID="lblUCCRMTitle" runat="server" Text="Relation" CssClass="styleTitle"></asp:Label> <asp:Panel ID="pnlRelation" runat="server" Width="100%" ScrollBars="auto"> <telerik:RadGrid ID="rgRelation" runat="server" AllowFilteringByColumn="True" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CellSpacing="0" DataSourceID="sqlDSRGRelation" GridLines="None" PageSize="20" Skin="Windows7" OnItemCommand="rgRelation_ItemCommand" onitemcreated="rgRelation_ItemCreated"> <ExportSettings ExportOnlyData="true" Excel-Format="ExcelML" > <Excel Format="ExcelML"></Excel> </ExportSettings> <ClientSettings><Resizing ClipCellContentOnResize="false"/> </ClientSettings> <MasterTableView DataKeyNames="RelationID" DataSourceID="sqlDSRGRelation" CommandItemDisplay="Bottom" InsertItemDisplay="Bottom"> <CommandItemTemplate> <div id="CommandItemTemplate"> <div id="CommandItemTemplateLeft"> <asp:LinkButton ID="lbnAddRecord" runat="server" CssClass="CommandItemLinkButton" CommandName="InitInsert"></asp:LinkButton> <span class="CommandItemTemplateDivider">|</span> <asp:LinkButton ID="lbnExportToExcel" runat="server" CssClass="CommandItemLinkButton" CommandName="ExportToExcel"></asp:LinkButton> <asp:LinkButton ID="lbnExportToPDF" runat="server" CssClass="CommandItemLinkButton" CommandName="ExportToPdf"></asp:LinkButton> <asp:LinkButton ID="lbnExportToCSV" runat="server" CssClass="CommandItemLinkButton" CommandName="ExportToCsv"></asp:LinkButton> <span class="CommandItemTemplateDivider">|</span> <asp:LinkButton ID="lbnRefresh" runat="server" CssClass="CommandItemLinkButton" CommandName="RebindGrid"></asp:LinkButton> <span class="CommandItemTemplateDivider">|</span> <asp:LinkButton ID="lbnSaveGridLayout" runat="server" CssClass="CommandItemLinkButton" CommandName="SaveGridLayout"></asp:LinkButton> </div> </div> </CommandItemTemplate> <CommandItemSettings ShowExportToPdfButton="true" ExportToPdfText="Export to PDF" ShowExportToExcelButton="true" ExportToExcelText="Export to Excel" ShowExportToCsvButton="true" ExportToCsvText="Export to CSV" > </CommandItemSettings> ..........