
hi ,,
I am using rad grid at webpart , using NestedItem at Grid but after Add Events Fixup Ajax working fine at all grid but i faced 2 issues please help me to find a soultion on them ...
1- the collapse buttom didn't work ( the grid post back and then the nested item didn't collapsed).
2- I can't expand more than 1 nested item at , if i trying to open nested item and it was one else opened the previous one collapsed and the new one expanded ,
here is rad grid code
| <telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="False" Skin="WebBlue" |
| AllowFilteringByColumn="true" dir="rtl" GridLines="None" AllowPaging="True" AllowSorting="True" |
| PageSize="15"> |
| <PagerStyle Mode="NumericPages" HorizontalAlign="Center" Font-Bold="true" VerticalAlign="Middle"> |
| </PagerStyle> |
| <GroupingSettings CaseSensitive="false" /> |
| <ItemStyle HorizontalAlign="Right" /> |
| <FilterItemStyle HorizontalAlign="Right" /> |
| <CommandItemStyle HorizontalAlign="Left" /> |
| <AlternatingItemStyle HorizontalAlign="Right" /> |
| <HeaderStyle HorizontalAlign="Right" /> |
| <MasterTableView DataKeyNames="STUDENTNO" GridLines="None" DataSourceID="ObjectDataSource1" |
| CommandItemDisplay="Top"> |
| <NoRecordsTemplate> |
| </NoRecordsTemplate> |
| <ExpandCollapseColumn Visible="True"> |
| </ExpandCollapseColumn> |
| <CommandItemTemplate> |
| <asp:LinkButton ID="clearFilter" runat="server" Text="Ù…Ø³Ø ÙƒÙ„ Ø§Ù„Ø¨ØØ«" ToolTip="الغاء Ø§Ù„Ø¨ØØ«" |
| OnClick="ClearFilter_Click" Font-Bold="true" Font-Size="14px"></asp:LinkButton> |
| </CommandItemTemplate> |
| <Columns> |
| ... SOME COLUMNS ... |
| </Columns> |
| <NestedViewTemplate> |
| <table> |
| ... NESTED TEMPATE GOES HERE ... |
| </table> |
| </NestedViewTemplate> |
| </MasterTableView> |
| <ClientSettings> |
| <Selecting AllowRowSelect="true" /> |
| </ClientSettings> |
| </telerik:RadGrid> |
| #region Events & Fixers |
| protected override void OnInit(EventArgs e) |
| { |
| base.OnInit(e); |
| ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page); |
| if (scriptManager == null) |
| { |
| scriptManager = new ScriptManager(); |
| scriptManager.ID = "ScriptManager1"; |
| this.Page.Form.Controls.AddAt(0, scriptManager); |
| } |
| RadAjaxManager ram = RadAjaxManager.GetCurrent(this.Page); |
| if (ram == null) |
| { |
| ram = new RadAjaxManager(); |
| ram.ID = "RadAjaxManager1"; |
| Page.Form.Controls.Add(ram); |
| Page.Items.Add(ram.GetType(), ram); |
| } |
| EnsureChildControls(); |
| } |
| protected override void OnPreRender(EventArgs e) |
| { |
| base.OnPreRender(e); |
| RadAjaxManager manager = RadAjaxManager.GetCurrent(Page); |
| if (manager != null) |
| { |
| manager.DefaultLoadingPanelID = this.EmployeesListUserControl.AjaxLoadingPanel.ID; |
| manager.AjaxSettings.AddAjaxSetting(this.EmployeesListUserControl.GridRootDep, this.EmployeesListUserControl.GridRootDep); |
| } |
| } |
| private void EnsureUpdatePanelFixups() |
| { |
| if (this.Page.Form != null) |
| { |
| string formOnSubmitAtt = this.Page.Form.Attributes["onsubmit"]; |
| if (formOnSubmitAtt == "return _spFormOnSubmitWrapper();") |
| { |
| this.Page.Form.Attributes["onsubmit"] = "_spFormOnSubmitWrapper();"; |
| } |
| } |
| ScriptManager.RegisterStartupScript(this.Page, typeof(Page), "UpdatePanelFixup", "_spOriginalFormAction = document.forms[0].action; _spSuppressFormOnSubmitWrapper=true;", true); |
| } |
| protected override void Render(HtmlTextWriter writer) |
| { |
| EnsureUpdatePanelFixups(); |
| base.Render(writer); |
| } |
| #endregion |
<
asp:Button ID="btnDelete" runat ="server" Text ="Delete" cssclass="RadUploadSubmit" OnClientClick="return OpenConfirm();"
Visible="False" />
function OpenConfirm() {
radconfirm(
'<h3 style=\'color: #333399;\'>Are you sure?</h3>', confirmCallBackFn, 330, 100, null, 'RadConfirm custom title');
return false;
function confirmCallBackFn(arg) {
radalert(
"<strnog>radconfirm</strong> returned the following result: <h3 style='color: #ff0000;'>" + arg + "</h3>", null, null, "Result");
}
Please tell me where do I modify javascript so it fires server side click after User selects Ok on confirmation dialog.
Thank you.
| <EditFormSettings EditFormType="Template"> |
| <FormTemplate> |
| <table id="tblAddEdit" cellspacing="1" cellpadding="1" width="100%" border="0" runat="server" > |
| <tr> |
| <td > |
| </td> |
| <td> |
| </td> |
| </tr> |
| <tr> |
| <td> |
| Course:</td> |
| <td> |
| <asp:DropDownList ID="cboCourse" runat="server" Width="200px" |
| TabIndex="1" AppendDataBoundItems="true"> |
| </asp:DropDownList> |
| <asp:RequiredFieldValidator ID="Requiredfieldvalidator00" Runat="server" Display="Dynamic" ControlToValidate="cboCourse" ErrorMessage="Select Course" /> |
| <asp:label ID="lblCourseID" runat="server" Visible="false" Text='<%# eval("CourseID") %>'></asp:label> |
| </td> |
| </tr> |
| <tr> |
| <td colspan="2" style="height:6px" > |
| </td> |
| </tr> |
| <tr> |
| <td> |
| Level:</td> |
| <td> |
| <asp:DropDownList ID="cboLevel" runat="server" Width="200px" |
| TabIndex="1" AppendDataBoundItems="true"> |
| </asp:DropDownList> |
| <asp:RequiredFieldValidator ID="Requiredfieldvalidator0" Runat="server" Display="Dynamic" ControlToValidate="cboLevel" ErrorMessage="Select Level" /> |
| <asp:label ID="lblLevelId" runat="server" Visible="false" Text='<%# eval("SubjectCode") %>'></asp:label> |
| </td> |
| </tr> |
| <tr> |
| <td colspan="2" style="height:6px" > |
| </td> |
| </tr> |
| <tr> |
| <td> |
| Teacher:</td> |
| <td> |
| <asp:DropDownList ID="cboTeacher" runat="server" Width="200px" |
| TabIndex="2" AppendDataBoundItems="true"> |
| </asp:DropDownList> |
| <asp:RequiredFieldValidator ID="Requiredfieldvalidator1" Runat="server" Display="Dynamic" ControlToValidate="cboTeacher" ErrorMessage="Select Teacher" /> |
| <asp:label ID="lblTeacherID" runat="server" Visible="false" Text='<%# eval("TeacherID") %>'></asp:label> |
| </td> |
| </tr> |
| <tr> |
| <td colspan="2" style="height:6px" > |
| </td> |
| </tr> |
| .... |
| .... |
| .... |
| </FormTemplate> |
| For example, |
| public void InstantiateIn(System.Web.UI.Control container) |
| { |
| RadTreeView RadTreeView1 = new RadTreeView(); |
| RadTreeView1.ID = "myTree" & myNumber |
| RadTreeView1.DataTextField = "Text"; |
| RadTreeView1.DataNavigateUrlField = "Url"; |
| RadTreeView1.DataFieldID = "ID"; |
| RadTreeView1.DataFieldParentID = "ParentID"; |
| RadTreeView1.DataSource = siteData; |
| RadTreeView1.DataBind(); |
| } |
After successfully installing RadControls_for_ASP.NET_AJAX_2009_2_826_trial.msi in Windows Vista Ultimate SP2 I took the exact same msi and tried to install it on Windows Server 2003 R2 SP2, but this time, after seeming to start fine, it puts up the following error pop-up:
The cabinet file 'media1.cab' required for this
installation is corrupt and cannot be used. This
could indicate a network error, an error reading
from the CD-ROM, or a problem with this
package.
Retry Cancel
No amount of Retry attempts helps.
Please don't tell me to download a fresh copy. This is the exact same MSI file that had zero problems installing on Vista SP2, so I am 100% confident that the msi is not corrupt.