- private void [dataGrideView 이름]_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
- {
- MessageBox.Show("선택한 row의 0번째cell의 값 == "
- + [dataGridView 이름].Rows[e.RowIndex].Cells[0].FormattedValue.ToString());
- }
[dataGridView 이름] 은 자신 해당 소스의 dataGridView name값을 넣어주면 됨.
dataGrideView에 이벤트를 걸어줍니다. 저는 CellDoubleClick(말 그대로 셀을 더블 클릭하면 벌어지는 이벤트)를 주었습니다.
'DEVELOPMENT' 카테고리의 다른 글
[WordPress] 간단한 소개 (0) | 2014.03.12 |
---|---|
[블로그] 프로그래밍 소스 코드 하이라이트 (0) | 2014.03.12 |
[이클립스] Line number 표시 (0) | 2014.03.09 |
[이클립스] 에디터 글꼴 변경하기 (0) | 2014.03.09 |
[C#] 텍스트박스에서 엔터키 이벤트 (0) | 2014.03.04 |