3

I'm trying to fire auto click on first row for a 'table' After Render. in icCube 6 (3961)

enter image description here

but when i use

function(context, data, $box) {
 context.fireRowClick(0)
}

i get error context.fireRowClick is not a function

Itay Regev
  • 191
  • 8

1 Answers1

2

This error has been repaired in >= icCube 6 (4036). Please update when it becomes available. As a workaround you could use the following fragment that sends event using the different context type:

function(context, data, $box) {
    if(context.fireRowClick){
        // context is table/widget context
        context.fireRowClick(0);    
    } else {
        // context is reporting context (before the fix)
        var axisIndex = data.getAxes().getAxisCount() - 1;        
        var event = new viz.event.SingleSelectionEvent({
            uniqueName : data.getAxes().getAxis(axisIndex).getMemberUniqueName(0,0),
            name : data.getAxes().getAxis(axisIndex).getMemberCaption(0,0),
        })
        context.eventMgr().fireEvent('rowClick', event)
    }
}
ic3
  • 7,917
  • 14
  • 67
  • 115
Sergey Ryskal
  • 388
  • 1
  • 9
  • i put 'rowClick' event name on do Click event in the table preferences but it didn't work. if i put the 'rowClick' event in do Selection for example then it worked fine and selected the first row. the thing is that i also have on Row Click event in the same table that should pop up a different graph with the row header name from the first table... – Itay Regev Mar 08 '17 at 10:55