How do i create and pass the event to event handler?
Basically i want to fire an event called key down on focus of text input box how do i do that?
This probably blog entry should help you.
<input type="text" onchange="alert('i was clicked')" id="test">
<script>
document.getElementById("test").onchange()
</script>
keydownisn't what you want - it won't cause a letter to be inserted.