I have a registration sort of page in my application. It has lots of textboxes,dropdowns and many other controls on it. Out of them some are mandatory and others are not. Form will be submitted only if mandatory fields are filled. Mandatory fields are differentiated from others by using specific CSS classes for them. For eg. If a textbox is mandatory then its css is txtbox_req otherwise its css would be just txtbox.
Now the problem is...
I have dropdown on the top of the page which has two options like 'Mandatory' and 'All'. Now my requirement is,..when user selects all..the tab index must be normal and on pressing tab the focus must be changing normally as usual betwwen all the controls on the page...If the user selects 'mandatory'..then the tab index of all the controls must be changed..and on pressing tab..the focus must be changing only to mandatory textboxes or dropdowns or any other controls..So, can anyone please suggest how to change the tab index of all the controls on selection of options form a dropdown..??!!