You must be logged in to post your query.
Home › Forums › Chart Support › tooltipcontent
Tagged: tooltip
how we can add icon in tooltipcontent
data:[ { type: “stackedBar100″, toolTipContent:”{z}<hr/>a”, name: “Accaptable”, dataPoints: [ {y: 450,z: “20”, color: “#2ca8e0”, indexLabel: “Accaptable”,indexLabelFontColor: “white”,indexLabelFontSize: 20}, ] }, i want to add icon in toolTipContent:”{z}<hr/>a”,in a word place when am write a its show but i want icon to write here and work properly
@amir-muneer,
You can use toolTipContent to add image inside the toolTip as shown in the code snippet below –
toolTipContent: "<img src=\"https://canvasjs.com/wp-content/uploads/images/gallery/javascript-column-bar-charts/\"{url}\"\" style=\"width:40px; height:20px;\"> <b>{label}</b><br>Budget: ${y}bn<br>{gdp}% of GDP",
Please take a look at this gallery page for an example along with working code on the same.
___________ Indranil Deo Team CanvasJS
You must be logged in to reply to this topic. Login/Register