PDA

View Full Version : ToolTip problem



extjs_Beginner
18 Sep 2015, 2:08 AM
Hello there,


I'm trying to display a tip values on a bar chart, but its not working.

This is my code :

tips: {
trackMouse: true,
width: 160,
height: 60,
html : 'Time' ,
renderer: function(storeItem, item, index) {

this.setTitle(storeItem.get('D'+index)+ ' secondes');
}
}

I have Undefined as a value on my bar chart.
I think that the problem comes from index, beacuse when I replace index by a value (3 or 5) I have a result.

any help please.
Thanks

Gary Schlosberg
18 Sep 2015, 5:28 AM
Looks like your renderer arguments need an adjustment:
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.chart.series.Bar-cfg-renderer

extjs_Beginner
18 Sep 2015, 5:35 AM
thank you Gary for your response.
I fixed with:

tips: {
trackMouse: true,
width: 160,
height: 60,
html : 'Duree de l\'alerte' ,
renderer: function(storeItem, item) {
this.setTitle('Duree :'+item.value[1]+ ' secondes');
}
}