0

When tabbing, focus should be only within the project create area... currently user is able to tab accross the tree, navigation pane etc.,

3
Contributors
4
Replies
5
Views
9 Years
Discussion Span
Last Post by SheSaidImaPregy
0

Set the tabstop property to false for the controls which are not
supposed to work on tab key press.

0

That works, but you will still tab out of the form area.

You need a javascript function:

function setFocus(input, objEvent) {
  if(objEvent.keycode == 66) {
    input.form[(getIndex(input)+1) % input.form.length].focus();
  }

  function getIndex(input) {
    var index = -1, i = 0, found = false;
    while (i < input.form.length && index == -1)
    if (input.form[i] == input)index = i;
    else i++;
    return index;
  }
  return true;
}

'' on page you need this under every field and button:
onkeypress="setFocus(this, event)"

If the key pressed is the tab key, it will automatically jump to the next corresponding field in the form. It will always stay within the form!

0

happy to help. I am a full-time javascript programmer who spent his life learning microsoft technologies. Figures right?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.