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
355
Select individual cells rather than rows in ultragrid
posted

I was wondering if it was possible to select individual cells rather than entire rows when clicking on a cell.  I would ideally like the selected cell to be tracked by my program (ie if the active data is being updated in a certain cell, I'd like that cell to be highlighted.  

I know that I can affect the appearance of a given cell via code.  For instance, if I want to change the cell in row 2, in the "Accepted" column to red, I can use the following code:

Me.VoltageGrid.Rows(2).Cells("Accepted").Appearance.ForeColor = Color.Red

However, I'd like to be able to select that cell programmatically AS I change the color, for instance.  So, I guess I have two questions, really:

1) Is there a way to change the features of the grid so that clicking on a cell will select the cell rather than the entire row?

2) Is it possible to select a given cell programmatically, similarly to the way I changed the color of a given call shown above?  

Thanks!