GridTemplateColumn field on EditForm

2 posts, 1 answers
  1. Kermit
    Kermit avatar
    20 posts
    Member since:
    Jan 2012

    Posted 25 Oct 2012 Link to this post

    How do I get an asp:label field that is contained within a GridTemplateColumn and bound to an underlying data field to appear as an editable field on an EditForm that is displayed by clicking Edit in a GridEditCommandColumn?
  2. Answer
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 25 Oct 2012 Link to this post


    Try using the GridTemplateColumn as follows.

    <telerik:RadGrid ID="rad" runat="server" DataSourceID="SqlDataSource1" AutoGenerateColumns="false">
                        <asp:Label runat="server" ID="Label1" Text='<%# Eval("OrderID") %>'></asp:Label>
                        <asp:TextBox ID="TextBox1" runat="server" Text='<%# Eval("OrderID") %>'></asp:TextBox>

Back to Top