Tool tip

In DHTMLX Grid present we are displaying the tool tip as



this.grid.tooltips(“Value,Value,Value,Value”);



then we are getting complete cell value as tool tip. But we need to restrict the tool tip length.

It should display only the 300 chars, for this how can we handle it in DHTMLX.



Please help me on this issue.



Thanks

Suresh.

There are few ways

a) you can use “title” attribute of cell element in XML ( or cell object in case of js api ) to set custom tooltip for the cell.

b) you can redefine default tooltip logic generation, just add next code before grid initialization

eXcell_ed.prototype.getTitle=function(){
var text = (_isIE ? this.cell.innerText : this.cell.textContent);
return text.substr(0,300); //not more than 300 chars
}

ed - type of column , for which tooltip generation logic will be redefined.

.