PDA

View Full Version : Problem in dynamic tooltip



chandan.behura
2 Sep 2012, 4:16 AM
Hi,
I have done with a toolTip action and the in the tolltip html i have a dynamic array.

But the problem is when i am getting the updated value of the array the tool tip still showing both the previous one and the current one.i want to destroy the previous tool tip.

Bellow is the screen shot of how i am getting the tool tip,
38406
the tooltips are coming one over another.
Bellow is my code,

My Dynamic array:( contains the values of selected rows )

var selected = [];
var selection = grid.getSelectionModel().getSelection();

for ( var i = 0; i < selection.length; i++) {
console.log(selection[i].data.all);
selected.push(selection[i].data.all);
}

My tooltip :


var tooltips = [{

target:Ext.getCmp('go').getEl(),
html: ''+selected+'',
autoDetroy:true

}
];

Ext.each(tooltips, function(config) {
Ext.create('Ext.tip.ToolTip', config);
});

Ext.QuickTips.init();


Anything more i want to solve my problem?

mitchellsimoens
17 Sep 2012, 6:26 AM
What component is this being used on? Or is this on simple HTML?