Click here to Skip to main content
11,717,570 members (80,446 online)
Rate this: bad
Please Sign up or sign in to vote.
Hi All,
How can we do some operations on selection changed in Data Grid View in WinForms.
I tried, DataGridView_SelectionChanged(...) but it make it complex in the data load too.
How Can I avoid this thing ?
Need suggestions.

Posted 9-Jul-12 0:56am
Edited 9-Jul-12 1:28am
(no name)104.2K
Wes Aday at 9-Jul-12 7:30am
After performing an exhaustive analysis of the code you submitted that describes your problem I have come to the conclusion that you might be able to solve your problem using a simple boolean flag.
Sandeep Mewara at 9-Jul-12 7:33am
This is not a well framed question! We cannot work out what you are trying to do/ask from the post. Please elaborate and be specific.
Use the "Improve question" link to edit your question and provide better information.

Elaborate on what operation you are trying. What is looking complex to you.
Itz.Irshad at 9-Jul-12 7:37am
Dear Aday and Sandeep,
Thanks for consideration. Well, I got solve this. Its an issue on selection changed event. Here is elaboration:
I have a Data Grid View in WinForm Application.
Now, I want to get selected row's specific column values (e.g. row 2 and column 3) in a text box on that form.
I hope you'll got what I mean to say.

biswarup88 at 10-Jul-12 14:44pm
have you tried cell click event in datagrid??

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 764
1 OriginalGriff 215
2 F-ES Sitecore 210
3 Maciej Los 140
4 Jochen Arndt 120
0 Sergey Alexandrovich Kryukov 1,494
1 OriginalGriff 535
2 Maciej Los 529
3 Richard MacCutchan 440
4 CHill60 415

Advertise | Privacy | Mobile
Web02 | 2.8.150901.1 | Last Updated 9 Jul 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100