2
Reply

How to insert a gridview values into DB

suchi rana

suchi rana

Jan 3 2012 2:10 AM
1.2k
Hi All,


I need to insert the gridview row values into DB.


this is my Gridview******************

<asp:GridView ID="GrdOptions" runat="server" AutoGenerateColumns="False"
Width="212px" ShowHeader="False">

<Columns>

<asp:TemplateField>
<ItemTemplate>
<asp:TextBox ID="txttask" runat="server" CssClass="Text" MaxLength="500"
Width="350px"></asp:TextBox>
</ItemTemplate>

</asp:TemplateField>
<asp:TemplateField>
<ItemTemplate>
<asp:TextBox ID="txthrs" runat="server" CssClass="Text" MaxLength="500"
Width="80px"></asp:TextBox>
</ItemTemplate>

</asp:TemplateField>
</Columns>
</asp:GridView>


***************************************************
i need to check the each row that how many rows have tha values based on this only i need to insert only that row has value.


Thanks in advance

Answers (2)