Datagrid programmatically deselect a cell

I am using a PDA in which I have a DataGrid that has a list of itemNames , barcode and scanStatus . The user scans the barcode and I search in my DataGrid for matching, and I select the row for the element associated with the barcode. I set scanStatus to true .

I had a problem with the user touching the screen and all rows of the DataGrid got unselected.

So, I tried to handle the events DataGrid Click , DoubleClick and MouseUp . I scroll through the grid where scanStatus is true and calls grid.Select(iteratorIndex) otherwise I call grid.UnSelect(iteratorIndex) .

This re-selects the rows of the scanned item. But the last cell that the user clicked also remains selected. How to deselect this cell? I did a search before publication, and the only thing that remotely corresponded to my situation was this thread , I tried advice there, but that, but that did not answer my question.

+2
winforms compact-framework
source share

No one has answered this question yet.

See similar questions:

8
Selecting an entire row instead of a cell in a DataGrid in Compact Framework

or similar:

thirteen
DataGridView: copy to clipboard
3
DataGridView Cell Binding Data
2
Is there a way to save the DataGridView row selected when the user clicks on a cell in another row?
one
Update DataGridView Cell Values ​​Immediately
one
.NET CF DataGrid redrawn without firing OnPaint?
one
Post MouseUp data change!
0
Is there a way in the property grid to deselect all grid elements programmatically?
0
Problems with DataGrid. Using DataSet.Merge with "Edit Template"
0
Closed form Trasnfer DataGrid
0
Remove all row selection options from datagridview topleft cell click in c #

All Articles