To get IE to focus on the new element, just have a short timeout...
/* Most of function here */
If you want answers, write a smart question
, someone probably does know how...
Oh, and if you want to learn, STFW