addEventlistner listens to function first or the variables?
<pre><code>var value;
addEventListener('GetPatientSearchValues', function() {
var value= 20;
FunctionName();
});

Function FunctionName();
{
   value = value + 1;
}
</code></pre>

<p>My problem is i need to recieve the value 20 and i need to pass it to FunctioName. But it directly calls the function... even an <code>alert(value)</code> does not work inside the Listener, but the alert works when i don't call another <code>function</code> inside my Listner.</p>
