Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
301 views
I have a combo box that I am attempting to populate in the page_load event and want the item in the combo box that corresponds to an incoming request string member value to be selected when done.  I have done this before and am not a "greenie", but I cannot get any item selected in the combo box.

The definition of the combo box is in the code block immediately below:
<telerik:RadComboBox ID="SearchCountry" TabIndex="5" style="z-index: 9000;" Width="200px" EnableEmbeddedSkins="true" Skin="Sitefinity" runat="server" Height="150px" OnClientSelectedIndexChanging="LoadSearchStateProv"></telerik:RadComboBox>

The server-side code behind code is immediately below this line:
Try
    Dim reader As SqlDataReader = cmd.ExecuteReader()
    Do While reader.Read()
        RCBI = New RadComboBoxItem()
        RCBI.Text = reader(sFieldToPopulate)
        RCBI.Value = reader("CodeList")
        If oValueToMatch = RCBI.Value Then
            RCBI.Selected = True
        End If
        RadComboBox1.Items.Add(RCBI)
    Loop
    reader.Close()
    reader = Nothing
Catch ex As Exception
    Throw New ApplicationException("Error reading to populate country combo box from Select Statement=" & ComboSelectStmt & ". Code=" & ex.Message)
Finally
End Try

Can you please tell me what I am doing wrong?  The combo box is being populated correctly...but no item is selected when the page_load event completes and the page is visible.  Why?

Thanks in advance!

Lynn
Lynn
Top achievements
Rank 2
 answered on 11 Jul 2011
2 answers
114 views
Hi all,

I have a grid created through declarative client side binding. Everything works fine but now I have added a combox and I would like the databind function to be called again as soon as an item is selected.

There is an example in the demo but it looks like this happening on the server side. I need this to happen on the client side. Here is my code:

<%@ Page language="C#" Codebehind="Custom_DealUI.aspx.cs" AutoEventWireup="false" Inherits="KF.Crm.Web.Custom_DealUI" %>
  
  
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
  
  
  
<head id="Head1" runat="server">
      
      
     
 <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
  
  
        <script type="text/javascript">
         
       <!--
            function OnClientSelectedIndexChangedEventHandler(sender, args) {            
              
            //NEED TO SOMEHOW CALL THE CLIENT SIDE DATABIND FUNCTION 
                  
            }
      
        function RadGrid1_DataBinding(sender, args) {
              
  
             
            var dataSourceLocation = args.get_location();
            var selectMethodName = args.get_methodName();
            var methodArguments = args.get_methodArguments();
  
           
              
            var startRowIndexParameterName = sender.ClientSettings.DataBinding.StartRowIndexParameterName;
            
            var maximumRowsParameterName = sender.ClientSettings.DataBinding.MaximumRowsParameterName;
              
            var sortParameterName = sender.ClientSettings.DataBinding.SortParameterName;
             
            var filterParameterName = sender.ClientSettings.DataBinding.FilterParameterName;
         
        }
          
        -->
    </script>
  
</telerik:RadCodeBlock>
  
    <style type="text/css">
        #mainForm
        {
            height: 646px;
        }
    </style>
  
</head>
<body class="BODY">
    <form runat="server" id="mainForm" method="post">
         
        <telerik:RadScriptManager ID="ScriptManager1" EnablePageMethods="true" runat="server" />
        <!-- content start -->
          <telerik:RadComboBox ID="RadComboBox1" runat="server" OnClientSelectedIndexChanged ="OnClientSelectedIndexChangedEventHandler"
  
       DataTextField="DealSelector"
      DataValueField="DealSelector" Culture="English (Australia)" 
            EnableAutomaticLoadOnDemand="True" Skin="Windows7"  >
              <Items>
                  <telerik:RadComboBoxItem runat="server" Text="All Deals" Value="All Deals" />
                  <telerik:RadComboBoxItem runat="server" Text="New Deals" Value="New Deals" />
                  <telerik:RadComboBoxItem runat="server" Text="Waiting Manager Approval" 
                      Value="Waiting Manager Approval" />
                  <telerik:RadComboBoxItem runat="server" Text="Manager Approved" 
                      Value="Manager Approved" />
                  <telerik:RadComboBoxItem runat="server" Text="Income Recognised" 
                      Value="Income Recognised" />
                  <telerik:RadComboBoxItem runat="server" Text="Pro-forma Invoice Created" 
                      Value="Pro-forma Invoice Created" />
                  <telerik:RadComboBoxItem runat="server" Text="Waiting Accounts Approval" 
                      Value="Waiting Accounts Approval" />
                  <telerik:RadComboBoxItem runat="server" Text="Invoiced" Value="Invoiced" />
                  <telerik:RadComboBoxItem runat="server" Text="Receipt Processed" 
                      Value="Receipt Processed" />
                  <telerik:RadComboBoxItem runat="server" Text="Credit Processed" 
                      Value="Credit Processed" />
                  <telerik:RadComboBoxItem runat="server" Text="Inactive" Value="Inactive" />
              </Items>
    </telerik:RadComboBox>
      
        <telerik:RadGrid ID="RadGrid1" AllowSorting="True" AllowPaging="True" 
            AllowFilteringByColumn="True" runat="server" CellSpacing="0" GridLines="None" 
            PageSize="100" Skin="Windows7" Culture="English (Australia)" 
             ShowStatusBar="True" Height="611px" style="margin-top: 34px">
            <MasterTableView>
<CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
  
<RowIndicatorColumn FilterControlAltText="Filter RowIndicator column"></RowIndicatorColumn>
  
<ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column"></ExpandCollapseColumn>
                <Columns>
                    <telerik:GridBoundColumn DataField="DealNo" HeaderText="DealNo" 
                AllowFiltering="True" >
                        <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                      
                   <telerik:GridBoundColumn DataField="ID" HeaderText="ID" 
                AllowFiltering="True" Visible="True" >
                        <HeaderStyle Font-Bold="True"  />
                    </telerik:GridBoundColumn>
                      
                        
          <telerik:GridBoundColumn DataField="Location" HeaderText="Location" 
                AllowFiltering="True" >
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
          <telerik:GridBoundColumn DataField="Department" HeaderText="Department" 
                AllowFiltering="False" >
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
          <telerik:GridBoundColumn DataField="LeadOp" 
                HeaderText="Lead Operative" AllowFiltering="True" >
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
          <telerik:GridBoundColumn DataField="TranType" 
                HeaderText="Transaction Type" AllowFiltering="False" >
                  
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                  
          <telerik:GridBoundColumn DataField="LevelSuite" HeaderText="Level Suite" 
                AllowFiltering="False" >
                  
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                  
          <telerik:GridBoundColumn DataField="Address" HeaderText="Address" 
                AllowFiltering="False" >
                  
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                  
          <telerik:GridBoundColumn DataField="KFAAmtExGST" 
                HeaderText="Amount Ex GST" AllowFiltering="False" DataType ="System.Decimal"  >
                  
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                  
          <telerik:GridBoundColumn DataField="DealStatus" HeaderText="Deal Status" 
                AllowFiltering="False" >
                  
              <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                  
          <telerik:GridBoundColumn DataField="GPDebtor" HeaderText="GP Debtor" 
                AllowFiltering="False" >
                <HeaderStyle Font-Bold="True" />
                    </telerik:GridBoundColumn>
                </Columns>
  
<EditFormSettings>
<EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
</EditFormSettings>
  
<PagerStyle AlwaysVisible="True"></PagerStyle>
            </MasterTableView>
<HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default"></HeaderContextMenu>
  
             
            <ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True" >
                <DataBinding Location="WebService.asmx"
                    SelectMethod="GetDataAndCount" SelectCountMethod="GetCount" 
                    EnableCaching="True" />
                <ClientEvents OnDataBinding="RadGrid1_DataBinding" />
                <Scrolling AllowScroll="True" UseStaticHeaders="True" />
                <Resizing AllowColumnResize="True" AllowResizeToFit="True" />
                  
                  
            </ClientSettings>
  
<FilterMenu EnableImageSprites="False"></FilterMenu>
        </telerik:RadGrid>
          
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" 
            BackImageUrl="loading.gif" BackgroundPosition="None" HorizontalAlign="Center" />
  
  
         
         
        <!-- content end -->
         
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" 
            DefaultLoadingPanelID="RadAjaxLoadingPanel1">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadGrid1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadGrid1" 
                            LoadingPanelID="RadAjaxLoadingPanel1"  />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
         
    </form>
</body>
</html>
Stanley
Top achievements
Rank 1
 answered on 11 Jul 2011
5 answers
719 views
Hi,

Radcombobox selectedindexchanged not firing when changing the index programmatically, I am changing the index as the code block below. The event is firing fine when changing the index manually from the screen
cbo_Mode.SelectedIndex = cbo_Mode.FindItemIndexByValue(SubmissionMode);
Pls guide me how to go about it.

Thanks
Jidesh
Cat Cheshire
Top achievements
Rank 1
 answered on 10 Jul 2011
6 answers
338 views
Hi All,

i have a page this used radgrid to retrieve data from database and i used a customized edit form which is shown as popup while editing and inserting records....

i noticed that when this popup is called for the first time...all controls in it are shown correctly in their postions including the update/insert and cancel buttons.... the popup is called when click on the edit/insert columns in the grid...

but after the first time and when the popup is called the update/insert button is moved up its position in the row...

i used html tables to design the popup template....

i don't know what is the reason for this behavior??? and how can be solved?

i have a second question regarding the grid direction attribute if from right to left...
the gird direction becomes from right to left correctly BUT the grid header, pager and filter row is expanded and controls are not in their expected positions.

i have attached a snapshot of the grid when it is left to right and right to left...

i hope can find the reason and solution of this problem????

thanks in adavnced

Asa'ad

Asa'ad
Top achievements
Rank 1
 answered on 10 Jul 2011
2 answers
44 views
Hi

I tried to use radeditor 4.5.6 in my webpart coding. I am getting the error message as "The type 'Telerik.SharePoint.MOSSRadEditor' has no constructors defined". It means "Radeditor Lite version" ?. Can we use this version in my webpart coding?.  I can't craete a instance for MoassRadEditor class. How can I use? if it is possible. Please guide me the correct way.

Thanaks in advance

selva
Top achievements
Rank 1
 answered on 09 Jul 2011
8 answers
702 views
Im reposting this here because someone moved my query to radmenu because i used it as an example. Ill paste my comments below...

Post 1.

After updating to the latest version of rad controls,  Visual Studio is not showing me the control formed correctly.
For example

<telerik:RadMenu ID="RadMenu3" Runat="server"></telerik:RadMenu

works fine, but

 

<telerik:RadMenu ID="RadMenu3" Runat="server" Skin="Forest"><CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation></telerik:RadMenu>

 


doesnt .

...and while you at it, can u put the colour controls in here, there is nothing more annoying then having to format text after copying and pasting.

Post 2.

ok, now the error for the ajax manager comes up as:
Error creating control - Rad Ajax Manager1

'AjaxSettings' could not be initialized. Detailes:[a]Telerik.Web.Ui.RadAjaxManager cannot be cast to[B]Telerik.Web.Ui.RadAjaxManager. Type A originates from 'Telerik.Web.Ui, Version=2008.3.1125.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4' in the context 'LoadNeither' at location 'C:\Documents and settingsMatthew\Local Settings\Application Data\Microsoft\VisualStudio\9.0\ProjectAssemblies\y5-i03sn01\telerik.web.ui.dll'. Type B originates from 'Telerik.Web.Ui, Version=2008.3.1125.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4' in the context 'LoadNeither' at location 'C:\Documents and settingsMatthew\Local Settings\Application Data\Microsoft\VisualStudio\9.0\ProjectAssemblies\z0ovsobn01\telerik.web.ui.dll'.

I have deleted the contents of 'C:\Documents and settingsMatthew\Local Settings\Application Data\Microsoft\VisualStudio\9.0\ProjectAssemblies' in case it was calling an old version, or it was cached or something.

If I drag a new control from th tool bar, then everything is fine until I try and change a setting


I really need some help on this as I have been able to do no work since installing the new controls


Michael
Top achievements
Rank 1
 answered on 08 Jul 2011
2 answers
167 views
Hi all,

I have grid that on insert / edit opens a RadWindow using functionality I have found on this website.  This default functionality uses a default view to present the edit form and I have amended it slightly changing two of the text boxes to a RadDatePicker and a RadEditor.  These additional RadControls bind properly but the binding appears to only be one way.  Upon update/insert any data in these RadControls is ignored and only the data from the text boxes goes into the database.

Can anyopne help me out please?  I have attached the code below:

PersonEditForm.aspx
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PersonEditForm.aspx.cs" Inherits="HonoursBoard.Admin.PersonEditForm" %> 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 
<html xmlns="http://www.w3.org/1999/xhtml" > 
    <head id="Head1" runat="server">  
        <title>Untitled Page</title> 
    </head> 
    <body> 
        <form id="form1" runat="server">  
            <telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
            </telerik:RadScriptManager> 
            <div> 
                <script type="text/javascript">  
                function CloseAndRebind(args)  
                {  
                    GetRadWindow().Close();  
                    GetRadWindow().BrowserWindow.refreshGrid(args);  
                }  
                       
                function GetRadWindow()  
                {  
                    var oWindow = null;  
 
                    if (window.radWindow)  
                        oWindow = window.radWindow; //Will work in Moz in all cases, including classic dialog  
                    else if (window.frameElement.radWindow)  
                        oWindow = window.frameElement.radWindow;//IE (and Moz as well)  
                        return oWindow;  
                 }  
                 function CancelEdit()  
                 {  
                    GetRadWindow().Close();    
                 }  
                </script> 
                <asp:DetailsView ID="DetailsView1" DataKeyNames="intPersonID" runat="server" AutoGenerateRows="False" 
                    DataSourceID="SqlDataSource1" Height="50px" Width="125px" OnItemCommand="DetailsView1_ItemCommand">  
                    <Fields> 
                        <asp:BoundField DataField="strTitle" HeaderText="Title" SortExpression="strTitle" /> 
                        <asp:BoundField DataField="strFirstName" HeaderText="First Name" SortExpression="strFirstName" /> 
                        <asp:BoundField DataField="strInitials" HeaderText="Initials" SortExpression="strInitials" /> 
                        <asp:BoundField DataField="strLastName" HeaderText="Last Name" SortExpression="strLastName" /> 
                        <asp:TemplateField HeaderText="Date Of Birth">  
                            <ItemTemplate> 
                                <telerik:RadDatePicker EnableViewState="false" MinDate="01/01/1850" 
                                    MaxDate="01/01/2100" Skin="Telerik" ID="RadDatePicker1" 
                                    DbSelectedDate='<%# DataBinder.Eval(Container.DataItem, "datDateOfBirth") %>' 
                                    Runat="server"></telerik:RadDatePicker> 
                            </ItemTemplate> 
                        </asp:TemplateField> 
                        <asp:TemplateField HeaderText="Biography">  
                            <ItemTemplate> 
                                <telerik:RadEditor EnableViewState="false" ID="RadEditor1" runat="server" Skin="Telerik" 
                                    ToolsFile="~/Editor/BasicTools.xml" Width="400px" Height="200px" 
                                    Content='<%# DataBinder.Eval(Container.DataItem, "strBiography") %>'>  
                                </telerik:RadEditor> 
                            </ItemTemplate> 
                        </asp:TemplateField> 
                        <asp:CommandField ShowEditButton="True" /> 
                        <asp:CommandField ShowInsertButton="True" InsertText="Add" /> 
                    </Fields> 
                </asp:DetailsView> 
            </div> 
            <asp:SqlDataSource ID="SqlDataSource1" runat="server"   
                ConnectionString="<%$ ConnectionStrings:dbGolfHonoursConnectionString %>"   
                InsertCommand="InsertAPerson" InsertCommandType="StoredProcedure"   
                SelectCommand="SelectPersonByPersonID" SelectCommandType="StoredProcedure"   
                UpdateCommand="UpdateAPerson" UpdateCommandType="StoredProcedure">  
                <SelectParameters> 
                    <asp:QueryStringParameter DefaultValue="0" Name="PersonID"   
                        QueryStringField="intPersonID" Type="Int32" /> 
                </SelectParameters> 
                <UpdateParameters> 
                    <asp:Parameter Name="intPersonID" Type="Int32" /> 
                    <asp:Parameter Name="strTitle" Type="String" /> 
                    <asp:Parameter Name="strFirstName" Type="String" /> 
                    <asp:Parameter Name="strInitials" Type="String" /> 
                    <asp:Parameter Name="strLastName" Type="String" /> 
                    <asp:Parameter Name="strBiography" Type="String" /> 
                    <asp:Parameter Name="datDateOfBirth" Type="DateTime" /> 
                </UpdateParameters> 
                <InsertParameters> 
                    <asp:Parameter Name="strTitle" Type="String" /> 
                    <asp:Parameter Name="strFirstName" Type="String" /> 
                    <asp:Parameter Name="strInitials" Type="String" /> 
                    <asp:Parameter Name="strLastName" Type="String" /> 
                    <asp:Parameter Name="strBiography" Type="String" /> 
                    <asp:Parameter Name="datDateOfBirth" Type="DateTime" /> 
                </InsertParameters> 
            </asp:SqlDataSource> 
        </form> 
    </body> 
</html> 


PersonEditForm.aspx.cs
using System;  
using System.Collections;  
using System.Configuration;  
using System.Data;  
using System.Linq;  
using Telerik.Web.UI;  
using System.Web;  
using System.Web.Security;  
using System.Web.UI;  
using System.Web.UI.HtmlControls;  
using System.Web.UI.WebControls;  
using System.Web.UI.WebControls.WebParts;  
using System.Xml.Linq;  
 
namespace HonoursBoard.Admin  
{  
    public partial class PersonEditForm : System.Web.UI.Page  
    {  
        protected void Page_Init(object sender, EventArgs e)  
        {  
            if (Request.QueryString["intPersonID"] == null)  
            {  
                DetailsView1.DefaultMode = DetailsViewMode.Insert;  
            }  
            else 
            {  
                DetailsView1.DefaultMode = DetailsViewMode.Edit;  
            }  
        }  
 
        protected void DetailsView1_ItemCommand(object sender, System.Web.UI.WebControls.DetailsViewCommandEventArgs e)  
        {  
            if (e.CommandName == "Update")  
            {  
                ClientScript.RegisterStartupScript(Page.GetType(), "mykey""CloseAndRebind();"true);  
            }  
            else if (e.CommandName == "Insert")  
            {  
                ClientScript.RegisterStartupScript(Page.GetType(), "mykey""CloseAndRebind('navigateToInserted');"true);  
            }  
            else 
            {  
                ClientScript.RegisterStartupScript(Page.GetType(), "mykey""CancelEdit();"true);  
            }  
        }  
    }  

Thanks in advance for any help offered,

Martyn
Hoon
Top achievements
Rank 1
 answered on 08 Jul 2011
1 answer
110 views
Hi, I would like to have a confirm button. Here what I have done so far:

Code-Behind:

protected void btnClear_Click(object sender, EventArgs e)

 

{

    RadWindowManager1.RadConfirm(

 

"ARE YOU SURE WANT TO CLEAR THE SEARCH FORM?", "buttonConfirm",450, 150, null, "INFO");

 

 

 

    if (hdfConfirm.Value == "true")

 

    {

        resetSearchForm();

    }

    

 

 

}


Javascript:

function

 

 

buttonConfirm(arg)
{
    if (arg)
    {
        //Set hidden field (hdfConfirm) value to true

 

        document.getElementById("<%=hdfConfirm.ClientID%>").value =

 

"true";

 

    }

 

 

    else 
    {
        //Set hidden field (hdfConfirm) value to false

 

        document.getElementById("<%=hdfConfirm.ClientID%>").value =

 

"false";

 

    }
    $find("<%=RadAjaxManager1.ClientID%>").ajaxRequest(arg);


 

But it didn't work. Would you please check to see if I'm missing something here?

 

Thanks

Lamk



LamKhoa
Top achievements
Rank 1
 answered on 08 Jul 2011
5 answers
245 views
I'm looking at your online demo for Exporting from the RadGrid.

http://demos.telerik.com/aspnet-ajax/grid/examples/generalfeatures/exporting/defaultcs.aspx

I immediately click on the "Export to Excel" button.  While reviewing the exported Excel or Word file, I notice that each textbox in the grid's footer has replicated itself 3 times for Page where I believe it should only display once.  Please see attached screenshot (exportexcel.jpg).

I am experiencing something similar when exporting a RadGrid to Excel with a RadTextbox visible on a grid row.  Please see screenshot of grid before exporting (exportgrid.jpg).  Please see screenshot of exported data (exportedtextbox.jpg). I'm my example, the textbox & value are duplicated.

My grid column is defined like this:

<telerik:GridTemplateColumn UniqueName="colUnits" HeaderText="Units">
   <HeaderStyle Width="100px" HorizontalAlign="Left" />
   <ItemStyle Width="100px" HorizontalAlign="Right" />
   <ItemTemplate>
      <telerik:RadNumericTextBox ID="txtUnits" runat="server" Width="40px" AutoPostBack="false"
         NumberFormat-DecimalDigits="0" CausesValidation="false" MinValue="0" MaxLength="3"
         NumberFormat-AllowRounding="false" Style="text-align:right;">
          <ClientEvents OnValueChanged="txtUnits_OnValueChanged" />
          <ClientEvents OnKeyPress="KeyPress" />
      </telerik:RadNumericTextBox>
   </ItemTemplate>
</telerik:GridTemplateColumn>

The grid is NOT in edit mode and I would like to just export the data inside the textbox. 

When I attempt to do the following setting:

grid.ExportSettings.ExportOnlyData = True

The column with the textbox does not get any data exported at all to Excel or PDF.

If

grid.ExportSettings.ExportOnlyData = False

Then I get the issue described above with the replicated data when exporting to Excel.  Still no data get exported for PDF.

I believe this is either an export setting issue, a formatting issue, or a bug with the export functionality.

Please advise.
Daniel
Telerik team
 answered on 08 Jul 2011
1 answer
87 views
Is there any issues with the ability to filter using a filter template with a radcomb box in version 2009.2.826.35?
I can load the grid, create the radcombo and fill it with values but when I select a value from the combo xo nothin happens.

<telerik:RadGrid ID="RadGrid1" runat="server"  AllowPaging="True" EnableLinqExpressions ="false"
                    PageSize="25" AutoGenerateColumns="False" GridLines="None" AllowSorting="True" Width="100%"
                    AllowFilteringByColumn="true" AlternatingItemStyle-BackColor="#eeeeee" ShowStatusBar="True"
                    OnNeedDataSource="RadGrid1_NeedDataSource" OnItemDataBound="RadGrid1_ItemDataBound"
                    OnInsertCommand="RadGrid1_InsertCommand" OnUpdateCommand="RadGrid1_UpdateCommand" 
                    OnItemCreated="RadGrid1_ItemCreated">
                     <PagerStyle AlwaysVisible="true" Mode="NextPrevAndNumeric" />
                            <MasterTableView CommandItemDisplay="Top" DataKeyNames="AuditID" EditMode="InPlace">
                                <AlternatingItemStyle BackColor="#EEEEEE"></AlternatingItemStyle>
                                <Columns>
                                    <telerik:GridEditCommandColumn UniqueName="EditCommandColumn" HeaderStyle-Width="50px" />                                    
                                    <telerik:GridTemplateColumn HeaderText="Branch" SortExpression="" UniqueName="CRDBranchNumber"  HeaderStyle-Width="160px">                                  
                                       <ItemTemplate>
                                          <asp:Label runat="server" ID="lbCRDBranchNumber" Text='<%# Eval("CRDBranchNumber") %>' />
                                       </ItemTemplate>
                                       <EditItemTemplate>
                                          <telerik:RadComboBox ID="rcbCRDBranchNumber" DataTextField="CRDBranchNumber" DataValueField="CRDBranchNumber" runat="server" Width="115px" />
                                           <asp:RequiredFieldValidator ID="RequiredFieldValidator1" ControlToValidate="rcbCRDBranchNumber" ErrorMessage="*"
                                                 runat="server" ToolTip="Branch is Required" InitialValue="Select Branch"  ForeColor="Red" />
                                          <asp:Label runat="server" ID="ldID" Visible="false" Text='<%# Eval("CRDBranchNumber") %>' />
                                       </EditItemTemplate>
                                    </telerik:GridTemplateColumn>                                        
                                    <telerik:GridTemplateColumn HeaderText="Auditor" SortExpression="" UniqueName="Auditor"  HeaderStyle-Width="225px">
                                       <ItemTemplate>
                                          <asp:Label runat="server" ID="lbAuditor" Text='<%# Eval("AuditorName") %>' />
                                       </ItemTemplate>
                                       <EditItemTemplate>
                                          <telerik:RadComboBox ID="rcbAuditor" DataTextField="AuditorName" DataValueField="AuditorID" runat="server" Width="175px" />
                                           <asp:RequiredFieldValidator ID="RequiredFieldValidator2" ControlToValidate="rcbAuditor" ErrorMessage="*"
                                                 runat="server" ToolTip="Auditor is Required" InitialValue="Select Auditor"  ForeColor="Red" />
                                          <asp:Label runat="server" ID="ldAuditorID" Visible="false" Text='<%# Eval("AuditorID") %>' />
                                       </EditItemTemplate>
                                    </telerik:GridTemplateColumn>                                                                                                
                                    <telerik:GridNumericColumn DataField="AuditYear" HeaderText="Audit Year" SortExpression="AuditYear" UniqueName="AuditYear" 
                                          DataType="System.Decimal" DataFormatString="{0:F0}" />                     
                                    <telerik:GridDateTimeColumn  SortExpression="ScheduledDate" DataField="ScheduledDate"
                                        HeaderText="Scheduled" DataType="System.DateTime" DataFormatString="{0:MM/dd/yyyy}"
                                        AllowFiltering="false" HeaderStyle-Width="100px" UniqueName="ScheduledDate" />
                                    <telerik:GridDateTimeColumn SortExpression="CompletedDate" DataField="CompletedDate"
                                        HeaderText="Completed" DataType="System.DateTime" DataFormatString="{0:MM/dd/yyyy}"
                                        AllowFiltering="false" HeaderStyle-Width="100px" UniqueName="CompletedDate" />                                        
                                    <telerik:GridTemplateColumn HeaderText="Status" SortExpression="" UniqueName="Status"  HeaderStyle-Width="195px">
                                       <FilterTemplate>
                                            <telerik:RadComboBox ID="rcbStatus" DataTextField="Status" DataValueField="Status"
                                                AppendDataBoundItems="true" SelectedValue='<%# ((GridItem)Container).OwnerTableView.GetColumn("Status").CurrentFilterValue %>'
                                                runat="server" AutoPostBack="true"  OnClientSelectedIndexChanged="TitleIndexChanged">
                                                    <Items>
                                                        <telerik:RadComboBoxItem Text="All" />
                                                    </Items>
                                                </telerik:RadComboBox>
                                                <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
                                                    <script type="text/javascript">
                                                        function TitleIndexChanged(sender,args) {
                                                            var tableView=$find("<%# ((GridItem)Container).OwnerTableView.ClientID %>");
                                                            tableView.filter("Status",args.get_item().get_value(),"EqualTo");                                                            
                                                        }
                                                    </script>
                                                </telerik:RadScriptBlock>
                                       </FilterTemplate>
                                       <ItemTemplate>
                                          <asp:Label runat="server" ID="lblStatus" Text='<%# Eval("Status") %>' />
                                       </ItemTemplate>
                                       <EditItemTemplate>
                                          <telerik:RadComboBox ID="rcbStatus" DataTextField="Status" DataValueField="AuditStatusID" runat="server" Width="150px" />
                                          <asp:RequiredFieldValidator ID="RequiredFieldValidator3" ControlToValidate="rcbStatus" ErrorMessage="*"
                                                 runat="server" ToolTip="Status is Required" InitialValue="Select Status"  ForeColor="Red" />
                                          <asp:Label runat="server" ID="lbAuditStatusID" Visible="false" Text='<%# Eval("AuditStatusID") %>' />
                                       </EditItemTemplate>
                                    </telerik:GridTemplateColumn>                                                                                
                                </Columns>
                                <EditFormSettings>
                                    <EditColumn InsertText="Insert Audit" UpdateText="Update Audit" UniqueName="EditCommandColumn1"
                                        CancelText="Cancel edit">
                                    </EditColumn>
                                </EditFormSettings>
                            </MasterTableView>

I can get this to work in another application but I am using 2009.3.1314.35.
Eric Klein
Top achievements
Rank 1
 answered on 08 Jul 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?