detect clicked column in datagrid

  • Thread starter Thread starter Sam
  • Start date Start date
S

Sam

Hi,
How can I detect if the cell on which the user clicked, belong to which
column of my datagrid ?

say if the user clicks on a cell in the second column, I would be able
to detect it is the second column.

Thx
 
not really :(
my main issue here is to detect the mouse click on a cell, and then to
figure out which column it belongs to.
thx
 
I found out :


intcolNum = dataGrid1.CurrentCell.ColumnNumber;

int rowNum = dataGrid1.CurrentCell.RowNumber;
 

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

Back
Top