| <telerik:GridTemplateColumn HeaderText="Phone process" UniqueName="PhoneProcess" Display="false" EditFormColumnIndex="1"> |
| <EditItemTemplate> |
| <div style="width:30ex;margin-right:1ex;"> |
| <telerik:RadComboBox runat="server" ID="ddlPhoneProcess" |
| Width="100%" |
| EmptyMessage="No phone processes found" |
| AllowCustomText="false" |
| DataValueField="Key" |
| DataTextField="Value" |
| AppendDataBoundItems="true" |
| AutoPostBack="true" |
| OnSelectedIndexChanged="ddlPhoneProcess_SelectedIndexChanged" |
| SelectedValue='<%# Bind("PhoneProcessId")%>' |
| > |
| <Items> |
| <telerik:RadComboBoxItem runat="server" Text="-- Not set --" Value="-1" Selected="true" /> |
| </Items> |
| </telerik:RadComboBox> |
| </div> |
| </EditItemTemplate> |
| </telerik:GridTemplateColumn> |
| RadComboBox combo = editItem["PhoneProcess"].FindControl("ddlPhoneProcess") as RadComboBox; |
| Dictionary<int, string> phoneProcesses = DataManagers.Proxy.DmPhone.GetPhoneProcesses(); |
| combo.DataSource = phoneProcesses; |
| combo.DataBind(); |
RadNumericTextBox
in other template columns bind with no problem.
If I databind the combo with DataSourceID="xxx" to a SqlDataSource, there is no error.
Could be that databinding via DataSource property somehow messes up the context of the databound control?
Really simple question. im working on the layout and design of my grid. how do i fill my ascx radgrid with dummy data? not looking to databind it to anything, just want to put 1 or 2 rows of dummy data in the columns collection.
| <telerik:RadGrid ID="RadGrid1" runat="server" Width="95%" AutoGenerateColumns="False" |
| PageSize="5" AllowSorting="True" AllowPaging="True" GridLines="None" ShowStatusBar="True" |
| > |
| <PagerStyle Mode="NumericPages"></PagerStyle> |
| <MasterTableView Width="100%" HierarchyLoadMode="ServerBind" DataKeyNames="ID" |
| HierarchyDefaultExpanded="True" |
| PageSize="5"> |
| <DetailTables> |
| <telerik:GridTableView runat="server" DataKeyNames="ID" Caption="Document Versions" |
| PageSize="5"> |
| <ParentTableRelation> |
| <telerik:GridRelationFields DetailKeyField="ID" MasterKeyField="ID" /> |
| </ParentTableRelation> |
| <Columns> |
| <telerik:GridBoundColumn DataField="ID" Visible="false" UniqueName="ID"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="DocumentNumber" HeaderText="Document Number" |
| UniqueName="DocumentNumber"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="Version" HeaderText="Document Version" UniqueName="Version"> |
| </telerik:GridBoundColumn> |
| </Columns> |
| </telerik:GridTableView> |
| <telerik:GridTableView runat="server" DataKeyNames="ID" Caption="Document Title" |
| PageSize="5"> |
| <ParentTableRelation> |
| <telerik:GridRelationFields DetailKeyField="ID" MasterKeyField="ID" /> |
| </ParentTableRelation> |
| <Columns> |
| <telerik:GridBoundColumn DataField="ID" Visible="false" UniqueName="ID"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="Title" UniqueName="Document Title"> |
| </telerik:GridBoundColumn> |
| </Columns> |
| </telerik:GridTableView> |
| </DetailTables> |
| <ExpandCollapseColumn Visible="True"> |
| </ExpandCollapseColumn> |
| <Columns> |
| <telerik:GridBoundColumn DataField="ID" DataType="System.Int32" UniqueName="ID" Visible="False" /> |
| <telerik:GridBoundColumn DataField="documentTitle" HeaderText="Document Title" UniqueName="documentTitle" |
| SortExpression="documentTitle" /> |
| <telerik:GridBoundColumn DataField="Primary POC" HeaderText="Primary POC" UniqueName="Primary POC" |
| ReadOnly="True" SortExpression="Primary POC" /> |
| </Columns> |
| </MasterTableView> |
| <FilterMenu EnableTheming="True"> |
| <CollapseAnimation Duration="200" Type="OutQuint" /> |
| </FilterMenu> |
| </telerik:RadGrid> |
// Summary:
// The ID property is reserved for internal use. Please use the Telerik.Web.UI.ControlItem.Value
// property or use the Telerik.Web.UI.Attributes collection if you need to assign
// custom data to the item.
Is there a way to get or set the ID, so that I can locate a specific tab on the server side polymorphically?
| <telerik:GridTemplateColumn UniqueName="TemplateColumn1"> |
| <ItemTemplate> |
| <div> |
| <table> |
| <tr> |
| <td colspan="2"> |
| <telerik:RadComboBox ID="rdDDB" runat="server" |
| onload="rdDDB_Load"> |
| </telerik:RadComboBox> |
| </td> |
| </tr> |
| <tr> |
| <td>Action 1</td> |
| <td>Action 2</td> |
| </tr> |
| </table> |
| </div> |
| </ItemTemplate> |
| </telerik:GridTemplateColumn> |
| protected void PManagerReqStmtGrid_ItemDataBound(object sender, GridItemEventArgs e) |
| { |
| RadComboBox rd = RadGrid.MasterTableView.Columns.FindByUniqueName("TemplateColumn1"); |
| } |


| <telerik:RadComboBox |
| ID="rcbsScopeOfWorkGroupDescription" |
| runat="server" |
| AppendDataBoundItems="true" |
| AllowCustomText="true" |
| DataSourceID="odsScopeOfWorkGroupDescription" |
| DataTextField="sScopeOfWorkGroupDescription" |
| DataValueField="sScopeOfWorkGroupDescription" |
| Text='<%# Bind("sScopeOfWorkGroupDescription") %>'> |
| <Items> |
| <telerik:RadComboBoxItem Text="" Value="" /> |
| </Items> |
| </telerik:RadComboBox> |
| <telerik:RadSpell |
| ID="rssScopeOfWorkGroupDescription" |
| runat="server" |
| ControlToCheck="rcbsScopeOfWorkGroupDescription" |
| IsClientID="false" |
| DictionaryLanguage="en-AU" |
| DictionaryPath="~/App_Data/RadSpell" /> |
