Как подсказка...
<!DOCTYPE html>
<html>
<head>
<title>test</title>
<style type="text/css">
</style>
<script type="text/javascript">
function Go() {
var val='Test'
setTimeout(function(){Test(val)},100);
}
function Test(Val) {
alert(Val)
}
</script>
</head>
<body>
<input type='button' value='Go' onclick='Go()' />
</body>
</html>