In my interface I have 7 label with already predetermined data and 7 textbox, each textbox is linked to a label. What I want is that when you write a number in a textbox that is in front of the label only the value is inserted in the code that indicates the label, so far I can only insert in a single field of the database and the code What I'm driving is this:
cmd.Parameters.AddWithValue("@codigo_integra", lbCodigo1.Text);
cmd.Parameters.AddWithValue("@cantidad", textBox1.Text);
I would like to know how I could do with the other 6 fields that I need because if I put the same code and change the label and the textbox I get an error that is already using.
In my database I have several codes and each code corresponds to a product. What I want is that when the user types a number in the texbox, that number is saved in the database. Example if in the code 284 in the textbox give 5 in the database I keep those 5, if in the code 288 in the textbox they give 10 in the database keep those 10 but only and only the product that is linked that code 288 or 284.