Microsoft's validators only work when they have a webcontrol or Htmlcontrol
object declared and that object uses the ValidationPrope rtyAttribute. I
suspect that Microsoft engineers are concerned by a couple of things with
hidden fields:
1. Many users declare hidden fields through Page.RegisterHi ddenField(). That
does not generate an object on the page. (Without an object, there is no
ValidationPrope rtyAttribute).
2. You can use a CustomValidator with a hidden field (only do not assign the
fieldID to the ControlToValida te property).
--- Peter Blum
www.PeterBlum.com
Email:
PL****@PeterBlu m.com
Creator of "Profession al Validation And More" at
http://www.peterblum.com/vam/home.aspx
<jo*****@driver .net> wrote in message
news:eO******** ******@TK2MSFTN GP15.phx.gbl...
I would go to lab.msdn.com and search for a prior bug that has been
filed about this. If you find one validate it and leave a comment (at the
bottom) and if you cannot find it then please post a new bug and then
reply to this tree with a link to it.
There have been multiple positions where Microsoft has decided to not
allow us to use or validate Hidden Input controls and I fail to see why
they continously decide to remove the Hidden fields from databinding and
data validation options.
"Eran Dvey-Aharon" <er**@prosight. com> wrote in message
news:ce******** *************** ***@posting.goo gle.com... Hi NG!
It seems to me that for some reason the validation objects don't know
how to work with controls of type 'HiddenField'.
It doesn't make any sence - because they are actually rendered as
<input type=hidden> on the client side, while regular textboxes that
rendered almost in the same way know how to be validated.
Any idea how to work-around this problem?
Eran Dvey-Aharon
ProSight Inc.