I have a supposedly simple application that will enable end users to modify account contact information for our order acknowledgement email system. I would like to simply present them with a grid that they can make changes to, and it saves after you leave the row a la Access.
I have the beginnings under way and am using a button to test my db save code, but I keep running into an error saying that I dont have a key value column defined.
"Dynamic SQL generation for the UpdateCommand is not supported against a SelectCommand that does not return any key column information."
Below is my code snipet, I tried searching through the previously asked questions here but was not able to find any help specific to my needs. If anyone here can provide any insight I would be most grateful. Thanks.
Private adapter As SqlDataAdapter
Private myDataSet As DataSet
Private Sub frmMain_Load(ByVal sender As Object, ByVal e As System.EventArgs) _
PBPPEconn = modPBPPurchasingEmailPODB.GetConnectString
Dim myBindingSource As New BindingSource
Dim strSQL As String = "SELECT * FROM PBPEDIByEmailList"
Dim conn As New SqlConnection(PBPPEconn)
Dim cmd As New SqlCommand(strSQL, conn)
adapter = New SqlDataAdapter(cmd)
myDataSet = New DataSet
myBindingSource.DataSource = myDataSet.Tables(0).DefaultView
Private Sub cmdUpdate_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) _
Dim cb As SqlCommandBuilder = New SqlCommandBuilder(Me.adapter)
Catch ex As Exception