-
March 20th, 2014, 03:50 PM
#1
Detect field changes in user control and then save changes to database
I have a client that wants to update a customer's information (to the database) when one or more fields change in my server user control. The page is presented by a grid in the center of the content area with a customer summary on the right (the user control). When a user selects a new customer in the grid the summary section on the right grabs the customer info from the DB and refreshes the fields on the customer panel on the right. This panel has text boxes and drop down lists that the user can change values in.
I don't want to update the customer's DB record each time a particular field changes but would rather just fire it off just once preferably before the user selects a different customer (row) in the grid or when the control 'looses focus'.
How can I do this? I'm thinking maybe with some clever JavaScript to tell me when one or more fields have changed and set a dirty flag that can then be interrogated that then can cause a postback so I can save the customer fields back to the DB.
Any help would be appreciated.
Steve
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|