2
Answers

how to bind HiddenField value

Aamir Khan

Aamir Khan

12y
7.3k
1
Hi friends,
i have a Field named KitID i am using it as hiddenfield like below

<asp:TemplateField>

<ItemTemplate>

<asp:HiddenField ID="KitID" runat="server" Visible="false"/>

</ItemTemplate>

</asp:TemplateField>

but while saving i am getting the error,

while saving i am using the below code:

string K = GridView1.Rows[i].Cells[0].FindControl("KitID");

cmddtls.Parameters.Add(

is der any other way to save it?

Pls reply!

regards,

aamir

"@KitId", SqlDbType.Int).Value = int.Parse(KitId);

Answers (2)