s s

s s

  • NA
  • 1
  • 0

Check Datagridview check box value

Dec 10 2009 9:15 PM

I created a simple table in access. Col1 is Yes/No, col2 is date/time, col3 is Yes/No, col4 is text.
Using Studio 2005, I created a Windows project and added a DataGridView, connecting to the access database.
This added 2 components: the xxbindingsource and the xxtableadapter.
While clicked on the DataGridView, I right clicked on the DataGridView and selected Edit columns.
My intention: when the user clicks on the checkbox in col1 populate col2 with the date/time stamp of this action and display on the form.
question: I am new to the .net world and kind of confused on how to access col1 from the datagridview (since I have 2 fields col1 and col3 that are both "check boxes") and which is the most appropriate event to use to verify if col1 is checked to populate col2 with the date/time stamp of when col1 was checked.
From my reading, I think I can use the DataGridViewCheckBoxCell, but since this checkbox is within a grid I am kind of stumped on how exactly to access it. Any code to accomplish this will help.

Answers (1)