Hi,

I'm not sure it's really an error, and surely a htmlunit Guru (Marc ?) can answer better than me, but your html is formatted a way that seems too weird to me to be well understood by htmlunit.

<HTML>
<!-- ASP Stuff -->
</HTML>

<SCRIPT language="JavaScript">
<!--//
                //other functions
                
                function ValidarFormulario()
                {                       
                        //inner stuff
                
                }
// no "// -->" end of javascript-style comment

</SCRIPT>

<DIV></DIV>

That could be a reason for which Webtest doesn't find the Javascript function ValidarFormulario()...

Hope that's not stupid and that could help

Florent

Pingwy
27, rue des arènes
49100 Angers



Test BCN a écrit :
I've just started with webtest, and I could make some simple tests, but when it comes to more deep tests, just trying to logon, I always bump onto javascript errors,...

Is it because I don't know how it works, or because it's not supported? What can I do?

It is saying that a function is not defined, but I can see it in the page.

JavaScript error loading page http://www.laboris.net/Laborislogin.aspx?ReturnUrl=%2fCandidato%2fCandidato-AreaPersonal.aspx: ReferenceError: "ValidarFormulario" is not defined. (onclick event for HtmlButtonInput[<input name="btnEntrar_div_en" id="btnEntrar_div_en" type="button" class="submit" style="width:55px;height:20px;cursor:pointer;" value="Entrar" onclick="EnabledRndButton(&apos;btnEntrar&apos;,false);if(!ValidarFormulario()){return false;};__doPostBack(&apos;btnEntrar&apos;,&apos;&apos;);">]#1)


      Location

C:\software\Laboris\tests\Usuario\loginUsuario.xml (line: 15)


      Details

javascript error ReferenceError: "ValidarFormulario" is not defined. (onclick event for HtmlButtonInput[<input name="btnEntrar_div_en" id="btnEntrar_div_en" type="button" class="submit" style="width:55px;height:20px;cursor:pointer;" value="Entrar" onclick="EnabledRndButton(&apos;btnEntrar&apos;,false);if(!ValidarFormulario()){return false;};__doPostBack(&apos;btnEntrar&apos;,&apos;&apos;);">]#1)
line    1
javascript source       function () { [native code, arity=0] }
failing line    function () {
javascript call stack ReferenceError: "ValidarFormulario" is not defined. (onclick event for HtmlButtonInput[<input name="btnEntrar_div_en" id="btnEntrar_div_en" type="button" class="submit" style="width:55px;height:20px;cursor:pointer;" value="Entrar" onclick="EnabledRndButton(&apos;btnEntrar&apos;,false);if(!ValidarFormulario()){return false;};__doPostBack(&apos;btnEntrar&apos;,&apos;&apos;);">]#1) at (onclick event for HtmlButtonInput[<input name="btnEntrar_div_en" id="btnEntrar_div_en" type="button" class="submit" style="width:55px;height:20px;cursor:pointer;" value="Entrar" onclick="EnabledRndButton(&apos;btnEntrar&apos;,false);if(!ValidarFormulario()){return false;};__doPostBack(&apos;btnEntrar&apos;,&apos;&apos;);">]:1)


Reply via email to