Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    ListGrid\TreeGrid field’s change event

    SmartClient _v111p_2017-07-03_LGPL

    The ListGrid and TreeGrid fields have a change/changed event. They appear to be identical in timing. I can call a function from this event, but are there any parameters to determine which record fired the event? The calls getCellCSSText and canEditCell make rowNum and colNum available, but not change event.


    Code:
    { name: "Auditability" , title: "Audit." , width: 50, canEdit: true , type: "boolean", canToggle: true, change: function (rowNum, colNum) { VerifyCheckboxes(rowNum, colNum, this); }, }

    #2
    You can use getEditRow() / getEditCol() at any time to find out the current cell being edited.

    Comment


      #3
      I am missing something here. Let me give you the specifics. I am using a TreeGrid which gets its structure from a Tree. The TreeGrid has cell editing. There is a function on the “changed” event of a Boolean (check box) field, which does get called when clicked.

      The TreeGrid (isoConfigTree ) returns undefined for isoConfigTree.getEditRow() and the function appears defined as:
      Function isc_ListGrid_getEditRow()(return this.$285)

      The getEditCol() has the same result. It returns undefined. The function appears defined as:
      Function isc_ListGrid_getEditCol()(return this.$30u)

      The variables $285 and $30u do not appear in the TreeGrid instance.

      Comment


        #4
        If there's no editor showing (see ListGridField.canToggle), you can use getEventRow() and getEventColumn() instead.

        Comment


          #5
          Thanks, that did the trick.

          Comment

          Working...
          X