Bhavdhuti,
I only glanced at the code, it doesn't appear to do what you want. You want to identify the control with the lowest tabindex...or you can to add a custom property to your controls and set a flag (at design time) on the control you want to the first to receive focus.
I'll try to get back to later today with some code...
>You mean that I should do the code in the init(), but the code in itself is it okay?
>
Steve Gibson