Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to test if we have Page_Validators
Message
 
 
To
All
General information
Forum:
ASP.NET
Category:
Client-side development
Title:
How to test if we have Page_Validators
Environment versions
Environment:
ASP.NET
OS:
Windows XP
Database:
MS SQL Server
Miscellaneous
Thread ID:
01327711
Message ID:
01327711
Views:
96
Hi everybody,

I have the following code:
function showReqFld(){
    var pBlk=parent.document.getElementById('spnStat').innerHTML;
    if(!pBlk||pBlk.match("Edit")) {
       if (Page_Validators) {
        for (i=0;i<Page_Validators.length;i++) {
            if(Page_Validators[i].innerHTML.match('Required'))Page_Validators[i].style.display="block";
        }   
       } 
    }
    var Loading = parent.document.getElementById('loading');
    if (Loading)
        Loading.style.display="none";
}
However, despite the added check for if (Page_Validators) it still fails saying Page_Validators is undefined. What is the appropriate way to test for the existence of Page_Validators?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Next
Reply
Map
View

Click here to load this message in the networking platform