Trigger Key jQuery
var e = jQuery.Event("keydown");
e.which = 50; // # Some key code value
$("input").trigger(e);
Delightful Dogfish
var e = jQuery.Event("keydown");
e.which = 50; // # Some key code value
$("input").trigger(e);