Custom grid column tooltip


#1

I have a requirement to change the default tooltip of the grid header column. How can i archive that?


#2

I use the DHX Tooltips with all of my DHX Grids and I’ve never had a problem. Tooltips can also be easily modified with CSS (shown in my code). Here is an example:

grid.events.on(“headerCellMouseOver”, function(column,e) {
if(column.id == “col1”){ show_col1(e.target) }
if(column.id == “col2”){ show_col2(e.target) }
if(column.id == “col3”){ show_col3(e.target) }
});

function show_col1(node) {
dhx.tooltip(“Tooltip message”, {node: node, position: “bottom”, css: “tooltip”});
}
function show_col2(node) {
dhx.tooltip(“Tooltip message”, {node: node, position: “bottom”, css: “tooltip”});
}
function show_col3(node) {
dhx.tooltip(“Tooltip message”, {node: node, position: “bottom”, css: “tooltip”});
}


#3

Great, this solution helped me a lot
Where can I find documentation on DHX Tooltips? I would like to know more about this.

Thank you for your help.


#4

The docs I’ve used for the tooltips can be found here https://docs.dhtmlx.com/suite/message/configuration/ and here https://docs.dhtmlx.com/suite/message/api/api_message_properties/#tooltip. I hope this helps.


#5

Perfect, thank you very much for the help, hugs.