Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

Make Textbox visible with javascript

$
0
0

I get this error when trying to make a textbox visible, can you help?

Microsoft JScript runtime error: Unable to get value of the property 'style': object is null or undefined.
on either of the bolded lines below.

Control:
<asp:TextBoxID="txtFromDate"text="From:"style="visibility:hidden"runat="server"></asp:TextBox>

<script type="text/javascript">

        function CheckFreq()
         {
      var MyFreq = document.getElementById("<%=cmbFreq.ClientID%>").value;
      var tb=document.getElementById("txtFromDate");

          if (MyFreq == "R")
          {// tb.style.display="block"; tb.style.visibilty="visibile";           }
         else
            tb.style.display="none";
            }</script>



Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>