I want to show a tooltip when I move the mouse. Here is my code:
private void Grid_MouseMove(object sender, MouseEventArgs e) { Grid grid = (Grid) sender; if (e.GetPosition(grid).X < 100) grid.ToolTip = e.GetPosition(grid).X.ToString(); else grid.ToolTip = null; }
However, the tooltip disappears after clicking on the grid.
Is there a way to get the tooltip to show?
source share