Call JavaScript method on dynamic form element
<p>I am creating new textbox using JavaScript. I want to call a JavaScript method onkeyup event of this newly created textbox. How will I do this?</p>

<p>Below is my code:</p>

<pre><code>var element2 = document.createElement("input"); 
element2.type = "text"; 
element2.id='complete-field'+tableID;
element2.name=tableID;
</code></pre>
