Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
570
CSOM Help - Tab/Focus override
posted

I'm a new user to the Aikido framework, and I'm finding it pretty frustrating exploring the CSOM javascript functions.  All I want to do is to skip over a column when a user hits the tab.  I dont know of a way to control tabindex, therefore I figure I could control the ExitedEditMode event and manually skip over the column, but havent been able to execute it.  Any help is greatly appreciated.

Parents
  • 150
    posted

    I am new to infragistics products.  This forum seems quite weak on examples and answers to questions.  After muddling through many partially answered questions, I worked out a way to skip columns I don't want the grid to stop at.  Here is the code that I pieced together from the sample referenced in one reply.  This code will jump to the 8th (index 7) cell (as my readonly cells are at the left of the grid)  Fro some reason, the readonly property is not exposed in the javascript.  

     

            function wdg_Activation_ActiveCellChanging(sender, eventArgs) {

                ///<summary>

                ///

                ///</summary>

                ///<param name="sender" type="Infragistics.Web.UI.WebDataGrid"></param>

                ///<param name="eventArgs" type="Infragistics.Web.UI.ActiveCellChangingEventArgs"></param>

     

                var grid = $find("<%= wdg.ClientID %>");

                var cell = eventArgs.getNewActiveCell();

                var row = cell.get_row();

                var newEditCell = null;

     

                if (cell.get_index() < 6) {

                    newEditCell = row.get_cell(7);

                }

     

                if (newEditCell != null) {

                    var editingBehavior = grid.get_behaviors().get_editingCore().get_behaviors().get_cellEditing();

     

                    // timeout needed to avoid entering exitEdit mode again - and end in recursion / stack overflow

                    window.setTimeout(function() {

                        editingBehavior.enterEditMode(newEditCell);

                    }, 200);

                    return false;

                }

            }

Reply Children