I have Explorer.aspx that defines a RadWindowManager as seen below:
<telerik:RadWindowManager ID="radWinMgr" runat="server" AutoSize="true" EnableShadow="true" ReloadOnShow="true" ShowContentDuringLoad="false" VisibleStatusbar="false" OnClientClose="fncClientClose"> <Windows> <telerik:RadWindow ID="rwUploadParent" runat="server" Behaviors="Close" NavigateUrl="Upload.aspx"></telerik:RadWindow> <telerik:RadWindow ID="rwDownloadParent" runat="server" Behaviors="Close" NavigateUrl="Download.aspx"></telerik:RadWindow> </Windows></telerik:RadWindowManager>
The OnClientClose function that you see referenced above is defined as follows:
<script type="text/javascript"> function fncClientClose(winNewRep, args) { var arg = args.get_argument(); if (arg == 1) { //Refresh file explorer: var oExplorer = $find("<%=radExplorer.ClientID%>"); var dirPath = oExplorer.get_currentDirectory(); if (dirPath) oAjaxPanel.ajaxRequest(dirPath); } }</script>
The purpose of the function is to refresh the RadFileExplorer, but this function never gets called. I have a button click the opens Upload.aspx as a RadWindow as follows:
<asp:Button ID="btnUpload" runat="server" Text="Upload" OnClientClick="fncOpenPopupWin('UploadMgr.aspx?UpFolder=', 'rwUploadParent'); return false;" />
As you see the OnClientClick of the button calls another function and passes the page name to open, including a query string parameter, and the name of the RadWindow:
<script type="text/javascript"> function fncOpenPopupWin2(strPage, strParent) { var varLocation = "/Root"; var winNewRep = radopen(strPage + varLocation, strParent); }</script>
When the button is clicked, page Upload.aspx opens, the user does what he/she wants, and then closes Upload.aspx. At that point, I expect the OnClientClose of the RadWindownManager to execute, but it never does.
I have read many postings about this kind of problem here on the forum, but none of the solutions have helped my situation. I appreciate any time someone takes to review this and offer suggestions.
Thank you,
Steven
<telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="true" AllowSorting="true" AutoGenerateColumns="False" GridLines="Both" OnNeedDataSource="RadGrid1_needdatasource" OnItemDataBound="RadGrid1_ItemDataBound" OnDetailTableDataBind="RadGrid1_DetailTableDataBind" OnItemCreated="RadGrid1_ItemCreated" AllowMultiRowSelection="true" AllowFilteringByColumn="true" OnItemCommand="RadGrid1_ItemCommand" SelectedItemStyle-CssClass="SelectedItem" Skin="Default"> <PagerStyle Mode="NextPrevNumericAndAdvanced" Position="TopAndBottom" AlwaysVisible="true" /> <ClientSettings EnableRowHoverStyle="true" EnablePostBackOnRowClick="true"> <Selecting AllowRowSelect="true" /> </ClientSettings> <FooterStyle BackColor="LightBlue" /> <MasterTableView ShowHeadersWhenNoRecords="true" AllowFilteringByColumn="true" DataKeyNames="RequestInfoID" Name="ApprovalsMaster"> <DetailTables> <telerik:GridTableView DataKeyNames="RequestInfoID" Width="80%" Name="ApprovalsDetail" AllowPaging="false" runat="server"> <ParentTableRelation> <telerik:GridRelationFields DetailKeyField="RequestInfoID" MasterKeyField="RequestInfoID" /> </ParentTableRelation> <Columns> <telerik:GridBoundColumn SortExpression="ApprovalLevelID" HeaderText="ApprovalLevelID" HeaderButtonType="TextButton" DataField="ApprovalLevelID" UniqueName="ApprovalLevelID"> </telerik:GridBoundColumn> <telerik:GridTemplateColumn HeaderText="Approve" UniqueName="ApproveRequest" AllowFiltering="false"> <ItemTemplate> <asp:Button runat="server" ID="btnApproveRequest" Text="Approve" CssClass="ButtonCSS" ToolTip="Click here to Approve Request" CausesValidation="False" OnClick="btnApproveRequest_Click" OnClientClick="javascript:var agree= confirm('Are you sure you want to approve this Request? '); if(agree){ Page_BlockSubmit = false;buttonClicked_WithObj(this); return true; };else {return false;};" CommandArgument='<%# Eval ( "RequestInfoID").ToString() + ";" + Eval ( "ApprovalLevelID").ToString() %>' /> </ItemTemplate> </telerik:GridTemplateColumn> </Columns> </telerik:GridTableView> </DetailTables> <Columns> <telerik:GridNumericColumn DataField="RequestInfoID" HeaderText="Request No." SortExpression="RequestInfoID" DataType="System.Int64" FilterControlWidth="40px"> </telerik:GridNumericColumn> <telerik:GridBoundColumn DataField="DepartmentName" HeaderText="Department" SortExpression="DepartmentName" UniqueName="DepartmentName"> </telerik:GridBoundColumn> </Columns> <EditFormSettings> <PopUpSettings ScrollBars="None" /> </EditFormSettings> <ExpandCollapseColumn Resizable="False" Visible="False"> <HeaderStyle /> </ExpandCollapseColumn> <RowIndicatorColumn Visible="False"> <HeaderStyle /> </RowIndicatorColumn> </MasterTableView> </telerik:RadGrid> OnDataBound="RadGrid1_DataBound" OnDataBinding="RadGrid1_DataBinding" protected void RadGrid1_DataBound(object sender, EventArgs e) { LoadGroupsExpandedState(RadGrid1); } protected void RadGrid1_DataBinding(object sender, EventArgs e) { SaveGroupsExpandedState(RadGrid1); } private void SaveGroupsExpandedState(RadGrid grid) { GridItem[] groupItems = grid.MasterTableView.GetItems(GridItemType.GroupHeader); if (groupItems.Length > 0) { List<string> collapsedIndexes = new List<string>(); foreach (GridItem item in groupItems) { if (!item.Expanded) { GridGroupHeaderItem groupHeader = (GridGroupHeaderItem)item; collapsedIndexes.Add(groupHeader.DataCell.Text); } } Session["groupExpandedState"] = collapsedIndexes; } } private void LoadGroupsExpandedState(RadGrid grid) { List<string> collapsedIndexes = Session["groupExpandedState"] as List<string>; if (collapsedIndexes != null) { foreach (GridItem item in grid.MasterTableView.GetItems(GridItemType.GroupHeader)) { GridGroupHeaderItem groupHeader = (GridGroupHeaderItem)item; if (collapsedIndexes.Contains(groupHeader.DataCell.Text)) { item.Expanded = false; } } } } public DataTable ProductDetailsDataTable{ get { return _productDetailsDataTable; } set { _productDetailsDataTable = value; //add code to read data from table and do something with it DataRow dr = _productDetailsDataTable.Rows[0]; RadImageEditor1.ImageUrl = dr["Image1Url"].ToString(); }}
<radA:RadAjaxManager runat="server" ID="radAjax" DefaultLoadingPanelID="AjaxLoadingPanel1" >
<AjaxSettings>
<rada:AjaxSetting AjaxControlID="RadGrid_NoReferrals">
<UpdatedControls>
<rada:AjaxUpdatedControl ControlID="RadGrid_NoReferrals" />
</UpdatedControls>
</rada:AjaxSetting>
</AjaxSettings>
</radA:RadAjaxManager>
Our circumstances:
Our Issue:
When we would attempt an export to PDF and we were setting the "ignorepaging" to true (as suggested in numerous posts), but we were still getting a Telerik error message. Doing searches through the system did not give us the exact resolution to the problem so alot of troubleshooting went on to resolve it.
Our Resolution:
Example:
myDataList.ExportSettings.ExportOnlyData = false;myDataList.ExportSettings.IgnorePaging = true;myDataList.ExportSettings.OpenInNewWindow = true;myDataList.ExportSettings.FileName = "Some_Name";myDataList.ExportSettings.Pdf.PageWidth = 1200;myDataList.Rebind();myDataList.MasterTableView.ExportToPdf();<telerik:RadDateInput id="del1" DateFormat="d" Width="92px" Height="18px" Font-Size="X-Small" Font-Names="Verdana" BorderWidth="1px" runat="server" > <ClientEvents OnKeyPress="del_keypress" /> <ClientEvents OnError="date_input_error" /> </telerik:RadDateInput>function del_keypress(sender, eventArgs) { var whichCode = eventArgs.get_keyCode(); if ((whichCode != 13) && ((whichCode < 47) || (whichCode > 57))) eventArgs.set_cancel(true);}function date_input_error(sender,args) { alert("Invalid Delivery Date"); sender.set_value(''); sender.focus();}