Insert validator error when updating
hi all ,
I have a Gridview and textboxes in the footer of all the attributes. The text boxes are to add new data into the grid. i also have a button in the footer which adds the new data in.
I have validators for my add new attributes, so if an attribute is not entered in, it will show a red star indicating in needs to be filled in.
This is where i have the problem, when i update a field, because the text boxes for the add are visible when i try to update a field the validators show saying that the fileds for adding a new record have not been entered, as a result the update does not occur.
To get around this problem i took out the validators and it worked like a charm, but i really want those validators in. is there any way i can have them in?
You may assign a ValidationGroup property to the validators and your Add button, so the validators fire when the Add button is clicked, but not when you edit a row in the GridView. See http://aspnet.4guysfromrolla.com/articles/112305-1.aspx for more information.
Please post questions to the forums, where others may benefit.
I do not offer free assistance by e-mail. Thank you!
Last Post: 12-13-2006, 02:49 PM
By zarien in forum Database
Last Post: 05-17-2006, 03:27 AM
By Tony Fountain in forum Database
Last Post: 02-04-2003, 04:30 PM
Last Post: 07-04-2001, 05:18 AM
By bigbastard4 in forum Database
Last Post: 05-16-2001, 06:24 PM
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center