asp.net - How to validate an ajax combobox with empty text? -
how should validate if ajax combobox
contains text? have tried asp.net requiredfieldvalidator
dosen't work.
if found solution here: http://ajaxcontroltoolkit.codeplex.com/workitem/24417
had add javascript change controltovalidate property internal textbox.
string script = string.format(@"if({0}) {0}.controltovalidate = ""{1}_textbox"";", this.reqvalidator.clientid, this.ddlcombo.clientid); scriptmanager.registerstartupscript(this, this.gettype(), string.format("validator trick {0}", this.clientid), script, true);
Comments
Post a Comment