jvoconnell
asked on
Best practices using ADO in web forms
Experts,
newbie question.
I am pulling data from a database and populating some text boxes and combo boxes. The users can edit/delete any of these fields. They can enter new data in a control that may have not contained data to begin with. The data is populated on the Load event. The user can do what they want and then click a "save" button.
What is a good practice to accomplish this? If the data adapter/data set are created in the Load, then they aren't available in the button_click, correct? Do you create "global" adapters/data sets?
Or
Would you populate the controls using a data reader and then use a command to update the database from the button click?
Any guidance is appreciated.
Thanks in advance.
newbie question.
I am pulling data from a database and populating some text boxes and combo boxes. The users can edit/delete any of these fields. They can enter new data in a control that may have not contained data to begin with. The data is populated on the Load event. The user can do what they want and then click a "save" button.
What is a good practice to accomplish this? If the data adapter/data set are created in the Load, then they aren't available in the button_click, correct? Do you create "global" adapters/data sets?
Or
Would you populate the controls using a data reader and then use a command to update the database from the button click?
Any guidance is appreciated.
Thanks in advance.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER