RequiredFieldValidator - on-the-fly changes

RequiredFieldValidator - on-the-fly changes

Post by Teemu Keis » Sun, 15 Feb 2004 02:45:30


You can use client-side API to enable it at client but as you set
Enabled=false at the server, you'd need to set it back at the server as well
(for server-side validation to work)

See this article for info about validator API:
http://www.yqcomputer.com/

--
Teemu Keiski
MCP, Microsoft MVP (ASP.NET), AspInsiders member
ASP.NET Forum Moderator, AspAlliance Columnist




I disable a RequiredFieldValidator (.Enabled=false) in Page_Load (WebForm
with C#). How can I enable the RequiredFieldValidator when I click a button
(e.g., in its event handler). I don't wan't to use validation until just
before I'm ready to leave the form. At present, my
RequiredFieldValidator.Enabled=true code requires that I click the exit
button twice before this enable takes effect. That's one too many times.
 
 
 

RequiredFieldValidator - on-the-fly changes

Post by Peter Blu » Tue, 17 Feb 2004 07:35:57

I posted this answer to your question on another newsgroup. (Its better not
to cross-post for this reason.) Either look at your posting on the newsgroup
microsoft.public.dotnet.framework.aspnet or use this link:

http://www.yqcomputer.com/ %40tk2msftngp13.phx.gbl&rnum=5&prev=/groups%3Fas_oq%3Dvalidate%2520validator%2520customvalidator%2520requiredfieldvalidator%2520regularexpressionvalidator%26safe%3Dimages%26ie%3DUTF-8%26oe%3DUTF-8%26as_ugroup%3Dmicrosoft.public.dotnet.framework.aspnet.*%26as_scoring%3Dd%26lr%3D%26hl%3Den

--- Peter Blum
www.PeterBlum.com
Email: XXXX@XXXXX.COM
Creator of "Professional Validation And More" at
http://www.yqcomputer.com/



well
http://www.yqcomputer.com/


button