Next Line of code is...?

G

Guest

I have a Windows datagrid, and I have finally figured out how to capture the
data in a particular cell on a mouse click:

DataGrid.HitTestInfo hitInfo = subsystemsDataGrid.HitTest(new Point(e.X,
e.Y));
subsystemsDataGrid.CurrentCell = new DataGridCell(hitInfo.Row,hitInfo.Column);
DataGridCell dc = subsystemsDataGrid.CurrentCell;
string txt = subsystemsDataGrid[dc].ToString();

Now I can do a switch statement and figure out which of three values I have.
What I need is the next line (or two) of code that will allow me to read
column 1 of the row that cell is in. I can select the row,

subsystemsDataGrid.Select(hitInfo.Row);

but how do I read column 1's value?

Thanks!

WhiteWizard (aka Gandalf)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top