Hi,
Here is the .ASPX Code for the RadGrid. Problem is, I am not able to Use Validation Controls(i.e.RequiredFieldValidator etc…) for the “txtRfqDetSize , txtRfqDetCubic AND cboItemID “ controls in the following scenario.
Any one will help me how to use Validation Controls in the following Scenario?
<telerik:RadGrid ID="rgRFQDetails" runat="server" AllowPaging="True" GridLines="Horizontal"
OnNeedDataSource="rgRFQDetails_NeedDataSource" Skin="Default" PageSize="10" Width="100%"
OnUpdateCommand="rgRFQDetails_UpdateCommand" OnDeleteCommand="rgRFQDetails_DeleteCommand">
<PagerStyle Mode="Slider" />
<%--<AlternatingItemStyle BackColor="#F1EFE9" />--%>
<MasterTableView AutoGenerateColumns="false" DataKeyNames="RFQDetails_RegSerLineNo"
EditMode="InPlace" CommandItemStyle-CssClass="RGCmdHeader" CommandItemSettings-RefreshText=" Refresh">
<Columns>
<telerik:GridBoundColumn Visible="false" DataField="RFQDetails_RegSerLineNo" HeaderText="Service L.No"
HeaderStyle-Width="15%" HeaderStyle-CssClass="GridHeadernew" UniqueName="RFQDetails_RegSerLineNo"
ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn Visible="false" DataField="RFQDetails_RegSerCode" HeaderText="Service Code"
HeaderStyle-Width="15%" HeaderStyle-CssClass="GridHeadernew" UniqueName="RFQDetails_RegSerCode"
ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="RFQDetails_RegSerName" HeaderText="Service Name"
HeaderStyle-Width="15%" HeaderStyle-CssClass="GridHeadernew" UniqueName="RFQDetails_RegSerName"
ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="RFQDetails_Coordinator" HeaderText="Coordinator"
HeaderStyle-Width="13%" HeaderStyle-CssClass="GridHeadernew" UniqueName="RFQDetails_Coordinator"
ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Commodity" HeaderText="Commodity" HeaderStyle-Width="13%"
HeaderStyle-CssClass="GridHeadernew" UniqueName="Commodity" ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="RFQDetails_WeightInLbs" ItemStyle-HorizontalAlign="Right"
HeaderText="Weights" HeaderStyle-Width="5%" HeaderStyle-CssClass="GridHeadernew"
UniqueName="RFQDetails_WeightInLbs" ReadOnly="True">
</telerik:GridBoundColumn>
<telerik:GridTemplateColumn HeaderText="Size" UniqueName="RFQDetails_Size" ItemStyle-HorizontalAlign="Left"
HeaderStyle-CssClass="GridHeadernew" HeaderStyle-Width="6%">
<ItemTemplate>
<telerik:RadTextBox Width="75%" Text='<%# Eval("RFQDetails_Size") %>' ID="txtRfqDetSize"
runat="server" onkeypress="fn_validateDecimal(this,'n')">
</telerik:RadTextBox>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="Cubic" UniqueName="RFQDetails_Cubic" ItemStyle-HorizontalAlign="Left"
HeaderStyle-CssClass="GridHeadernew" HeaderStyle-Width="6%">
<ItemTemplate>
<telerik:RadTextBox Width="75%" Text='<%# Eval("RFQDetails_Cubic") %>' ID="txtRfqDetCubic"
runat="server" onkeypress="fn_validateDecimal(this,'n')">
</telerik:RadTextBox>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="UM" UniqueName="RFQDetails_UOM" HeaderStyle-CssClass="GridHeadernew">
<ItemTemplate>
<telerik:RadComboBox ID="cboItemID" DataTextField="Lookup_Value" DataValueField="Lookup_Key"
Text='<%# Bind("RFQDetails_UOM") %>' OnInit="RadComboBox1_Init" EnableLoadOnDemand="True"
runat="server" Width="100px">
</telerik:RadComboBox>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderStyle-Width="7%" HeaderText="From" Visible="false"
HeaderStyle-CssClass="GridHeadernew">
<ItemTemplate>
<asp:Label ID="lblServiceLine" runat="server" Text='<%#Bind("RFQDetails_RegSerLineNo") %>'></asp:Label>
<asp:Label ID="lblServiceCode" runat="server" Text='<%#Bind("RFQDetails_RegSerCode") %>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridButtonColumn ConfirmText="Are you Sure to Update the Record" ConfirmTitle="Update1"
HeaderStyle-Width="3%" ButtonType="ImageButton" CommandName="Update" HeaderStyle-CssClass="GridHeadernew">
</telerik:GridButtonColumn>
<telerik:GridTemplateColumn HeaderText="Status" HeaderStyle-Width="8%" HeaderStyle-CssClass="GridHeadernew">
<ItemStyle HorizontalAlign="Left" />
<ItemTemplate>
<asp:CheckBox runat="server" Width="70" ID="chkRFQDetStatus" AutoPostBack="true" Checked='<%# CheckRecordStatus((bool)Eval("IsActive"))%>'
Text='<%# CheckText((bool)Eval("IsActive"))%>' OnCheckedChanged="chkRFQDetStatus_CheckedChanged" />
</ItemTemplate>
</telerik:GridTemplateColumn>
</Columns></MasterTableView></telerik:RadGrid>
Regards,
Ranganath.S