I have a .NET form using C# that I use for both editing a table and adding a new record. When editing, it grabs data from a record and fills the form text boxes with the info, and shows an "Edit" button. Click on "Edit" and it works fine. At the top, I have a "New" button. This is supposed to clear out the form of all values, and show a new button called "Add". I'm using a foreach loop to clear the text box controls, and on the screen the boxes do clear.
But regardless of when I type in new data and click "Add", it inserts a new record with the most previous record that had been pulled up into that form for an edit. So the "clearing" isn't working somehow. And it's no longer seeing what I'm putting into the text boxes.
Any help appreciated.
Mark
But regardless of when I type in new data and click "Add", it inserts a new record with the most previous record that had been pulled up into that form for an edit. So the "clearing" isn't working somehow. And it's no longer seeing what I'm putting into the text boxes.
Any help appreciated.
Mark