Welcome to the Xceed Community | Help
Community Search  
More Search Options

different cell forecolors in the selected row

Sort Posts: Previous Next
  •  02-04-2010, 3:09 PM Post no. 25666

    different cell forecolors in the selected row

    I found a solution (in this Forum) to allow the cell's background color to show through the SelectionBackColor, but is there a way to allow the cell's foreground color to show the SelectionForeColor?
    Filed under:
  •  02-08-2010, 12:55 PM Post no. 25698 in reply to 25666

    Re: different cell forecolors in the selected row

    Hi,

    you could refer to http://xceed.com/CS/forums/permalink/25629/25664/ShowThread.aspx#25664 ...  Other than these indications, I don't have other hints to give you.  Unless you can give us the ****exact behaviour**** that you can't obtain yet.

    Regards


    Ghislain
    Technical Support and software developer
    Xceed Software Inc.
    Knowledge Base : http://xceed.com/kb/
    Update Center : http://xceed.com/updates/
    Documentation Center : http://xceed.com/doc/
    For everything else, there is Google
  •  02-08-2010, 3:29 PM Post no. 25700 in reply to 25698

    Re: different cell forecolors in the selected row

    When a row is made current, all the cells in that row take on the forecolor of the selection bar.  I want to keep the cell's original forecolor and not have it replaced by the forecolor of the selection bar.

     

    Ghislain,

    For some reason my inquery "different cell forecolors in the selected row" is locked.  The answer you gave is not the answer to the question I asked.

    You answer deals with changing the forecolor of a cell being edited.

    My question was dealing with a row being selected.  I do not want to allow editing.

    "When a row is made current, all the cells in that row take on the forecolor of the selection bar.  I want to keep the cell's original forecolor and not have it replaced by the forecolor of the selection bar."

     

  •  02-10-2010, 10:39 AM Post no. 25735 in reply to 25700

    Re: different cell forecolors in the selected row

    Hi,

    this should do:

            public Form1()
            {
                Xceed.Grid.Licenser.LicenseKey = "GRD38-.....-.....-RNAA";
                InitializeComponent();
                gridControl1.SelectionMode = SelectionMode.None;
                foreach (Column column in gridControl1.Columns)
                {
                    column.CellEditorManager.SettingControlAppearance += new Xceed.Grid.Editors.CellEditorEventHandler(CellEditorManager_SettingControlAppearance);
                }
            }

            void CellEditorManager_SettingControlAppearance(object sender, Xceed.Grid.Editors.CellEditorEventArgs e)
            {
                e.Control.ForeColor = Color.Blue;
            }

            private void Form1_Load(object sender, EventArgs e)
            {
                // gridControl1.SingleClickEdit = true;   // to make the grid cells editable on a single click
            }


    Ghislain
    Technical Support and software developer
    Xceed Software Inc.
    Knowledge Base : http://xceed.com/kb/
    Update Center : http://xceed.com/updates/
    Documentation Center : http://xceed.com/doc/
    For everything else, there is Google
    Filed under: , , ,
View as RSS news feed in XML
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2011 Xceed Software Inc.