Hi All. I am trying to create code behind a button in the Gridview. The button will insert multiply rows from one table to another. I need to pass the Meeting ID from the tblMeetings table to the tblVotings table. The following code does not produce any errors, but it also does not insert any rows to the tblVotings table. What am I doing wrong in my code?

Imports System.Data Imports System.Data.SqlClient Partial Class _NewMeetings Inherits System.Web.UI.Page Public Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click Dim strConnection As String = ConfigurationManager.ConnectionStrings("ServiceLine_CommitteeConnectionString").ConnectionString Dim con As New SqlConnection(strConnection) Dim cmd As New SqlCommand("insert into tblVotings(Meeting_ID, Committee_ID, Member_Name) SELECT M.ID, C.ID, CM.FULL_N ...

Go to the complete details ...