This is my code:
Add_click
dbcmd = New SqlCommand("INSERT INTO dms(name, dept) VALUES (@name, @dept)", connection)
'Add Database Parameters
dbcmd.Parameters.Add("@name", SqlDbType.VarChar).Value = name.Text
dbcmd.Parameters.Add("@dept", SqlDbType.VarChar).Value = dept.Text
But I want to add the data in gridview
Dim record_series As String = DirectCast(GridView1.FindControl("Record_Series_Number"), Label).Text
Dim doc_name As String = DirectCast(GridView1.FindControl("Document_Name"), Label).Text
Please help.. thanks in advance..:)