Not getting memory for Validator control in Javascript
<p>I was reading an article to disable validators in Javascript using below mentioned reference</p>

<p><a href="http://geekswithblogs.net/jonasb/archive/2006/08/11/87708.aspx" rel="nofollow">http://geekswithblogs.net/jonasb/archive/2006/08/11/87708.aspx</a></p>

<hr>

<p><strong>My practice page</strong></p>

<pre><code>&lt;%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default4.aspx.cs" Inherits="Default4" %&gt;

&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head runat="server"&gt;
    &lt;title&gt;&lt;/title&gt;
    &lt;script language="javascript" type="text/javascript"&gt;
        function RegexTester(ID) {
            debugger;
            var ID1 = document.getElementById('req');
            //            ValidatorEnable(
            return false;
        }
    &lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
    &lt;form id="form1" runat="server"&gt;
    &lt;div&gt;
        &lt;asp:RegularExpressionValidator ID="req" runat="server" ErrorMessage="hi" ControlToValidate="TextBox1"
            ValidationExpression="^[0-9]{7,20}$" EnableClientScript="false"&gt;
        &lt;/asp:RegularExpressionValidator&gt;
        &lt;asp:TextBox ID="TextBox1" runat="server" CausesValidation="false"&gt;&lt;/asp:TextBox&gt;
        &lt;asp:CheckBox ID="btn" runat="server" Text="Regex Tester" CausesValidation="false"
            AutoPostBack="true" /&gt;
    &lt;/div&gt;
    &lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<hr>

<p><strong>Query</strong></p>

<p>In the javascript function, I am unable to get the memory for required field validator control. I mean ID1 is showing null value...Why?</p>
