Unable to call javascript function from external.js file
<p>I am unable to call my javascript function named as clear which takes a string parameter the parameter value im passing by calling that function on client click.
here is my code please do help me in this </p>

<pre><code>&lt;script type="text/javascript"&gt;       
    var _whichform = 'login'
    function clear(_whichform)
    {

        switch (_whichform)
        {
        case 'login':
               document.getElementById('&lt;%=tbxUsername.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxPassword.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxFname.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxLname.ClientID%&gt;').value = ''
               break;
          break;
         case 'company':
               document.getElementById('&lt;%=tbxCompname.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxDescptn.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCompanyEmail.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxStateCo.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxStateCo.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCity.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCompanyAddress.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCpCountryCode.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCpStateCode.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxPhone.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCfCountryCode.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCfStateCode.ClientID%&gt;').value = ''
               document.getElementById('&lt;%=tbxCffax.ClientID%&gt;').value = ''
          break;

        }
    }
&lt;/script&gt;
&lt;input id="btnLoginCancel" type="button" value="Clear" onclick="clear('login')" class="buttons"/&gt;
</code></pre>
