if this is so, I did a solution, which might be the right one:
Private Sub button1_Click(sender As Object, e As EventArgs)
Dim amount As Integer = 0
If Integer.TryParse(textBox1.Text, amount) Then
Dim cake As String = comboBox1.Text
For i As Integer = 0 To table.Rows.Count - 1
If ds.Tables("CakePie").Rows(i)("Name").ToString() = cake Then
ds.Tables("CakePie").Rows(i)("Amount") = amount
da.Update(ds, "CakePie")
con.Close()
Exit For
End If
Next
Else
MessageBox.Show("Input is not in correct format.")
End If
End Sub
Be aware of one thing: Names as: "Name" and "Amount" in the for loop are the same names as your dataBase names for CakeName and CakeAmount.