Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
180
How to hide a tooltip in a grid column
posted

I have a grid that has tooltips turned on:

this.gridTransactions.DisplayLayout.Override.TipStyleCell = TipStyle.Show;


In the MouseMove event I basically show the cell text in the tooltip:
        private void gridTransactions_MouseMove(object sender, MouseEventArgs e)
        {
            UIElement mouseupUIElement = gridTransactions.DisplayLayout.UIElement.ElementFromPoint(new Point(e.X, e.Y));
            UltraGridCell currentCell = null;

            if (mouseupUIElement != null)
            {
                currentCell = mouseupUIElement.GetContext(typeof(UltraGridCell)) as UltraGridCell;
            }

            if (currentCell != null)
            {
                SetTxnGridCellToolTip(currentCell);
            }
        }

In this grid I have two columns where the cells have a EditorWithText editor with buttons.  I don't want the tooltip to show in these columns.  How do I show the tooltip in all but cells in these two columns?

  • 69832
    Offline posted

    UltraGridCell exposes a Column property, so your 'SetTxnGridCellToolTip' method could check the column first and if it is one of the columns for which you want to prevent the tooltip from displaying, don't display the tooltip.