child combo doesnot get populated on changing parent combo on up/down key press while navigated through tab control
i have 2 combobox A & B.. the values in B is populated according to selected value in A,, my code works fine when i click combo A and select a item,, the values according to开发者_如何学Go it get populated on combo B. i have written it on the change event...
But when i use tab to navigate and select the items in combo A and change on pressing keyboard down key...the items in combo B is not getting populated with new values.. existing values does not get changed,,, ie change event is not getting fired... how can i manage it in down/up key in keyboard when using tab,,,,
You can solve this by binding to both the change
and keyup
events:
$(".yourClass").bind("change keyup", function() {
alert("changed");
});
jsFiddle example
精彩评论