Hello,
I have a function called stateChanged:
function stateChanged()
{
alert(xmlHttp.r eadyState)
if (xmlHttp.readyS tate==4)....... .............
............... ............... .
}
When I call it with:
xmlHttp.onready statechange=sta teChanged()
I get an error: Type mismatch.
When I call it with
xmlHttp.onready statechange=sta teChanged
It runs fine.
Whats wrong with the parenthesis in the function call?
Thanks
Mike
I have a function called stateChanged:
function stateChanged()
{
alert(xmlHttp.r eadyState)
if (xmlHttp.readyS tate==4)....... .............
............... ............... .
}
When I call it with:
xmlHttp.onready statechange=sta teChanged()
I get an error: Type mismatch.
When I call it with
xmlHttp.onready statechange=sta teChanged
It runs fine.
Whats wrong with the parenthesis in the function call?
Thanks
Mike
Comment