This example shows how to display super tooltips with images when a user hovers over a row indicator.
See the implementation of the ToolTipController.GetActiveObjectInfo event:
private void toolTipController1_GetActiveObjectInfo(object sender, ToolTipControllerGetActiveObjectInfoEventArgs e) {
if (e.SelectedControl != gridControl1) return;
ToolTipControlInfo info = null;
SuperToolTip sTooltip1 = new SuperToolTip();
try {
GridView view = gridControl1.GetViewAt(e.ControlMousePosition) as GridView;
if (view == null) return;
GridHitInfo hi = view.CalcHitInfo(e.ControlMousePosition);
if (hi.HitTest == GridHitTest.RowIndicator) {
info = new ToolTipControlInfo(GridHitTest.RowIndicator.ToString() + hi.RowHandle.ToString(), "Row Handle: " + hi.RowHandle.ToString());
ToolTipTitleItem titleItem1 = new ToolTipTitleItem();
Image im = view.GetRowCellValue(hi.RowHandle, "Picture") as Image;
ToolTipItem item1 = new ToolTipItem();
item1.Image = im;
sTooltip1.Items.Add(item1);
}
info = new ToolTipControlInfo(hi.HitTest, "");
info.SuperTip = sTooltip1;
}
finally {
e.Info = info;
}
}
(you will be redirected to DevExpress.com to submit your response)