<
radg:radgrid id="rgPhysician" runat="server" AllowFilteringByColumn="True" AllowSorting="True"AutoGenerateColumns="False" GridLines="None" EnableAJAX="True" Skin="WebBlue" >
<MasterTableView>
<Columns>
<radG:GridTemplateColumn UniqueName="TemplateColumn" AllowFiltering="False">
<ItemTemplate>
<asp:LinkButton ID="btnShowDetails" runat="server" CausesValidation="false" Text="Select" >
</asp:LinkButton>
<cc1:ModalPopupExtender ID="ModalPopupExtender1" runat="server" PopupControlID="Panel1"
OkControlID="btnOK" TargetControlID="btnShowDetails" BackgroundCssClass="modalBackground" DropShadow="true">
</cc1:ModalPopupExtender>
<asp:Panel ID="Panel1" runat="server" BackColor="Beige" Font-Bold="True" style="display: none">
<table border="1" style="width: 500px; height: 300px">
<tr>
<td colspan="4">
<img src="Images/a.gif" style="width: 25px; height: 18px" /><span style="font-size: 10pt"><strong>Aultman
Hospital Phone Book
</strong></span></td>
</tr>
<tr>
<td style="width: 125px">
<strong><span style="font-size: 10pt">
Name:</span></strong></td>
<td colspan="3">
<asp:Label ID="lblName" runat="server" Text='<%# Eval("PhysFullName") %>'></asp:Label></td>
</tr>
<tr>
<td style="width: 125px">
<strong><span style="font-size: 10pt">
Speciality:</span></strong></td>
<td colspan="3">
<asp:Label ID="Label1" runat="server" Text='<%# Eval("PhysSpeciality") %>'></asp:Label><strong><span style="font-size: 10pt"></span></strong></td>
</tr>
<tr>
<td style="width: 125px">
<strong><span style="font-size: 10pt">
Extension:</span></strong></td>
<td colspan="3">
<asp:Label ID="lblExt" runat="server" Text='<%# Eval("Ext") %>'></asp:Label><strong><span style="font-size: 10pt"></span></strong></td>
</tr>
<tr>
<td style="width: 125px;">
<strong><span style="font-size: 10pt">
Office:</span></strong></td>
<td colspan="3">
<asp:Label ID="Label3" runat="server" Text='<%# Eval("Office") %>'></asp:Label></td>
</tr>
<tr>
<td style="width: 125px;">
<strong><span style="font-size: 10pt">
FAX:</span></strong></td>
<td colspan="3">
<asp:Label ID="Label5" runat="server" Text='<%# Eval("FAX") %>'></asp:Label></td>
</tr>
<tr>
<td style="width: 125px;">
<strong><span style="font-size: 10pt">
Staff:</span></strong></td>
<td colspan="3">
<asp:Label ID="Label2" runat="server" Text='<%# Eval("Denotes") %>'></asp:Label></td>
</tr>
<tr>
<td style="width: 125px;">
<strong><span style="font-size: 10pt">
Practice:</span></strong></td>
<td colspan="3">
<asp:Label ID="Label4" runat="server" Text='<%# Eval("PhysPractice") %>'></asp:Label></td>
</tr>
<tr>
<td style="text-align:center;" colspan="4">
<asp:Button ID="btnOK" runat="server" Text="OK" Width="94px" /></td>
</tr>
</table>
</asp:Panel>
</ItemTemplate>
</radG:GridTemplateColumn>
<radG:GridBoundColumn DataField="PhysID" Display="False" HeaderText="PhysID"
ReadOnly="True" UniqueName="PhysID">
</radG:GridBoundColumn>
<radG:GridBoundColumn DataField="ContactType" Display="False" HeaderText="ContactType"
ReadOnly="True" UniqueName="ContactType">
</radG:GridBoundColumn>
<radG:GridBoundColumn DataField="PhysFullName" HeaderText="Name" UniqueName="PhysFullName">
</radG:GridBoundColumn>
<radG:GridBoundColumn DataField="PhysSpeciality" HeaderText="Speciality" UniqueName="PhysSpeciality">
</radG:GridBoundColumn>
<%--<radG:GridBoundColumn DataField="PhysPractice" HeaderText="Practice" UniqueName="PhysPractice">
</radG:GridBoundColumn>
<radG:GridBoundColumn DataField="Denotes" HeaderText="Staff" UniqueName="Denotes">
</radG:GridBoundColumn>
<radG:GridBoundColumn DataField="Ext" HeaderText="Ext" UniqueName="Ext">
</radG:GridBoundColumn>--
%>
<radG:GridBoundColumn DataField="Office" HeaderText="Office" UniqueName="Office">
</radG:GridBoundColumn>
<%-- <radG:GridBoundColumn DataField="FAX" HeaderText="FAX" UniqueName="FAX">
</radG:GridBoundColumn>--
%>
</Columns>
<RowIndicatorColumn Visible="False">
<HeaderStyle Width="20px" />
</RowIndicatorColumn>
<ExpandCollapseColumn Visible="False">
<HeaderStyle Width="19px" />
</ExpandCollapseColumn>
</MasterTableView>
</
radg:radgrid>
Hello All,
I had this issue with creating modalpopup inside radgrid and was able to fix it and it worked OK, now the problem I am having is when there are 304 records the select button freezes the page and works occasionaly.
I created the modalpopup to contain all the data so it wouldn't have to post back with the server when i click on the select button. Included is the code and HTML on the page. Any help would be really appreciated.
Hi everyone
I have the following scenario:
§ A rad splitter (that have size of 100% width and height) with two panes (say left and right).
§ The left pane is scrollable one.
§ A rad menu resides inside the left pane.
§ When the length of the rad menu is greater that the length of the left pane the menu appears outside the boundary of that rad pane.
How can I solve this problem?
I tried the following with no benefits:
§ Adjust the z-index of the left pane and the rad menu.
§ read the KB that belongs to this issues.
Remarks:
§ I’m using rad controls for asp.net Ajax.
§ Microsoft asp.net with framework 3.5.
§ IE Version 7.
Thanks in advance
Hi,
how can i add new row to RadGrid while grid was bind
RadGrid1.DataSource=MyDataSet();
RadGrid1.DataBind();
Telerik.Web.UI.GridTableRow Str = new Telerik.Web.UI.GridTableRow();
Telerik.Web.UI.GridTableCell Stn = new Telerik.Web.UI.GridTableCell();
Telerik.Web.UI.GridTableCell Stn2 = new Telerik.Web.UI.GridTableCell();
Telerik.Web.UI.GridTableCell Stn3 = new Telerik.Web.UI.GridTableCell();
Telerik.Web.UI.GridTableCell Stn4= new Telerik.Web.UI.GridTableCell();
Telerik.Web.UI.GridTableCell Stn5 = new Telerik.Web.UI.GridTableCell();
Stn.Text = "Deniz";
Stn.BorderWidth = new Unit(1, UnitType.Pixel);
Stn.BackColor = Color.Red;
Str.Cells.Add(Stn);
Str.Cells.Add(Stn2);
Str.Cells.Add(Stn3);
Str.Cells.Add(Stn4);
Str.Cells.Add(Stn5);
RadGrid1.Controls.Add(Str);
my grid has 5 colums but thats code give only 1 colums
please help me
thx
DD
protected void Page_Load(object sender, EventArgs e)
{
if (Session["OFFICECODE"] == null)
{
Session[
"OFFICECODE"] = SecurityManager.GetOfficeCode(HttpContext.Current.User.Identity.Name);
Session[
"Office_Table"] = SecurityManager.GetOfficeCodeData(Session["OFFICECODE"].ToString());
if (((Admin.OfficeCodeDataTable)Session["Office_Table"]).Rows.Count != 0)
{
RadMenuItem NewItem = new RadMenuItem();
NewItem.ForeColor = System.Drawing.
Color.Blue;
NewItem.Text = ((
Admin.OfficeCodeDataTable)Session["Office_Table"])[0].SenatorElect;
NewItem.ToolTip = NewItem.Text;
NewItem.Width = 375;
this.RadMenu.Items.Add(NewItem);
}
}
// end if
}
|
Requirements |
|
| RadControls version |
2008.1.415.20 |
| .NET version |
2.0 |
| Visual Studio version |
2005 |
| programming language |
C# |
| browser support |
all browsers supported by RadControls |
| <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> |
| <%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> |
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
| <html xmlns="http://www.w3.org/1999/xhtml"> |
| <head runat="server"> |
| <title>Untitled Page</title> |
| </head> |
| <body> |
| <form id="form1" runat="server"> |
| <asp:ScriptManager ID="ScriptManager1" runat="server" /> |
| <div> |
| <br /> |
| <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:NorthwindConnectionString2 %>" |
| SelectCommand="SELECT [ShipName], [ShipCountry], [OrderID] FROM [Orders]"></asp:SqlDataSource> |
| <br /> |
| </div> |
| <br /> |
| <telerik:RadGrid ID="RadGrid1" DataSourceID="SqlDataSource1" Skin="Hay" AllowPaging="true" PageSize="5" AutoGenerateColumns="True" runat="server"> |
| <MasterTableView CommandItemDisplay="Top" DataSourceID="SqlDataSource1"> |
| <CommandItemTemplate> |
| <table> |
| <tr> |
| <td> |
| <asp:Label ID="Label1" runat="server" BackColor="Green" Text="Choose a Ship Country"></asp:Label> |
| </td> |
| <td> |
| <asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource1" |
| DataTextField="ShipCountry" DataValueField="ShipCountry" OnSelectedIndexChanged="DropDownList1_SelectedIndexChanged" > |
| </asp:DropDownList> |
| </td> |
| </tr> |
| </table> |
| </CommandItemTemplate> |
| <GroupByExpressions> |
| <telerik:GridGroupByExpression> |
| <GroupByFields> |
| <telerik:GridGroupByField FieldName="ShipCountry" FieldAlias="ShipCountry" FormatString="" HeaderText=""/> |
| </GroupByFields> |
| <SelectFields> |
| <telerik:GridGroupByField FieldName="ShipCountry" FieldAlias="ShipCountry" FormatString="" HeaderText=""/> |
| </SelectFields> |
| </telerik:GridGroupByExpression> |
| </GroupByExpressions> |
| <RowIndicatorColumn Visible="False"> |
| <HeaderStyle Width="20px" /> |
| </RowIndicatorColumn> |
| <ExpandCollapseColumn Resizable="False" Visible="False"> |
| <HeaderStyle Width="20px" /> |
| </ExpandCollapseColumn> |
| <EditFormSettings> |
| <PopUpSettings ScrollBars="None" /> |
| </EditFormSettings> |
| </MasterTableView> |
| </telerik:RadGrid><br /> |
| </form> |
| </body> |
| </html> |
| using System; |
| using System.Data; |
| using System.Configuration; |
| using System.Web; |
| using System.Web.Security; |
| using System.Web.UI; |
| using System.Web.UI.WebControls; |
| using System.Web.UI.WebControls.WebParts; |
| using System.Web.UI.HtmlControls; |
| using Telerik.Web.UI; |
| public partial class _Default : System.Web.UI.Page |
| { |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| } |
| protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) |
| { |
| DropDownList DropDownList1 = (DropDownList)sender; |
| int count = RadGrid1.MasterTableView.PageCount; |
| int flag = 0; |
| for (int i = 0; i < count; i++) |
| { |
| RadGrid1.CurrentPageIndex = i; |
| RadGrid1.Rebind(); |
| foreach (GridItem item in RadGrid1.MasterTableView.Controls[0].Controls) |
| { |
| if (item is GridGroupHeaderItem) |
| { |
| GridGroupHeaderItem Item = (GridGroupHeaderItem)item; |
| string strText = Item.DataCell.Text; |
| string[] arr = strText.Split(':'); |
| DataRowView groupDataRow = (DataRowView)Item.DataItem; |
| string searchText = groupDataRow[arr[0]].ToString(); |
| if (searchText == DropDownList1.Text) |
| { |
| searchText = "<span style='color: red;' >" + searchText + "</span>"; |
| Item.DataCell.Text = arr[0] + ":" + " " + searchText; |
| flag = 1; |
| break; |
| } |
| } |
| } |
| if (flag == 1) |
| break; |
| } |
| } |
| } |
And when you extract into wwwroot and try to access http://yourhost/SmallApp/SmallApp.aspx as a startup page.
Follow to Telerik MyPortal Example, I’ve put RadGrid inside a WebUserControl and
then RadDock will Load this WebUserControl to use further.
And now, here is my questions: (I also ask questions in .cs file to as a comment.)
Because I need to update RadDock from WebUserControl Event too and
that updated should not affect any other RadDock inside the same RadDockZone.
When using LoadControl method?
Because I need to make criteria from outside RadDock and send it to RadGrid
(inside WebUserControl via LoadControl) then rebind.
(3 docks in my SmallApp case), The data shows wrong information and it might be
Caused of RegisterJavaScript function that Telerik MyPortal Example gives me
But how to modify for this situations (to create more than 1 docks when hit button once)?
[To test this scenario you have to close and reopen IE again each time to see this problem]
[To see the correct information, try to change to Empty Page and then go back SmallApp.aspx again]
(such as rebind the RadGrid). How to do that? (I tried some codes in .cs file but it’s not work.)
(like Telerik MyPortal Example), The loading image won’t show.
So, go back to the point again. All I want to ask are:
- Access WebUserControl from RadDock (such as DockToggleButton Event)
- Access RadDock from WebUserControl (such as Page_Load Event)
- RadDock should be updatable by WebUserControl (because RadDock isn’t in any kind of UpdatePanel)
- How to send parameter to WebUserControl when using LoadControl from RadDock.
- Create multiple docks at one click button.
Brian,