Might there be an editNextCell?
actually it also looks as though the grid widget itself loses focus upon the tab event. So a click is still needed to start editing the next cell. Perhaps I have someting wrong.
is it referencing the selectNextCell function? I tried that and still couldn't get it to work.
It raises "selectNextCell" event in response to "onKeyTab" event and "selectPreviousCell" in response to "onKeyShiftTab".
ok, I again apologize for my lack of intelligence on this one, as you can see, i'm not much of a JS guy. I added the code you suggested, but its still not tabbing, I saw the event listed in _grid.js, it just doesn't seem to be firing off. What am I doing wrong here?
does not seem to be working properly in Firefox.
This was happening because of code I had in place to make single click edit cell work.
I have removed that code; now tab moves the selection over one cell then loses focus.
IE seems to work just fine.
was killing the tabbing functionality. Once I moved my code from there to a function called by <body onKeyDown=someFunction()> it worked! The only thng is when the tabbing does work, going from cell to cell doesn't LOOK like the focus is being set, the user has to begin for this to happen. Other than that, its working great!
Setting the controller to support tabbing works great. However, it only works within the current row.
1. On back tab, tab to the last column of the previous row?
2. On forward tab, tab to the first column of the next row?
3. On back tab when on the first column of the first row, tab out of the grid to the previous control (text input field etc)?
4. On forward tab when on the last column of the last row, tab out of the grid to the next control (text input field etc)?
You should look in /source/lib/grid/_actions.js - this is where all navigation actions are implemented and design something similar.
How would I add/insert my own navigation actions without modifying the _action.js code?
figured out how to do it. It appears that the action methods get added to the grid prototype. In my case we have extended the grid so the new methods have been added to the prototype of the extended grid. The following code tabs through all cells in a grid immediately putting the cell into edit mode (if it is editable). Supports back tab and forward tab. On tab from last cell goes to next tab-able component following grid. On backtab in first cell goes to previous tab-able component preceeding grid. After tabbing out of the grid and then back tabbing back into the grid, focus goes to the first cell in the grid which meets my needs. There is one issue where the user clicks to a component outside of the grid. On tab back into the grid, focus goes to the cell which last had focus. I'm pretty sure I can resolve that issue but that is low down on my list of priorities. I got to say that this is pretty cool control.
The example abowe works fine but if i instead of tab maps this to Enter it result is that i need to enter "Enter" 2 times.
But how to do if i want enter key to work like the tab example from Bryn.
You have to modify editing code to make it work for Enter key - the reason is that the Enter key is used by default to start editing and finish editing, and the event is cancelled when in edit mode.
I implemented the code above and found that when i use oncellvalidated, an error is not displayed when it occurs.
The focus stays in the current cell on (shitf)tab, however the selection does move to the next or previous cell.
when changing AW.setReturnValue(event, false); to AW.setReturnValue(event, true); the error does display, however the difference between the focus and selection still occurs.
Does anyone have an idea to catch the result of onCellValidated?
I also use an AW2 extended grid.
Where do I insert the above code?
I get an error: 'proto_type' is undefined.
when press tab, cell change but focus lost.
The above solution works fine for the textfields. But does not loose focus on tab if the cell is combo field.
it makes the text fields editable but tab key does not work on combo field.
can anyone guide me further.