Solved

Get current value of cell in bound datagridview

Posted on 2011-03-23
4
564 Views
Last Modified: 2012-05-11
I have a bound (List of (object)) datagridview with one column that is editable. I need to get the current value of the edited cell. At the moment it either returns me the value from the underlying dataset or in a different editmode it updates the underlying dataset and therefore I don't know if the row has been edited. I don't want to update the whole object as this would be take too much time. What is the best way of handling this?
0
Comment
Question by:suroma
  • 2
  • 2
4 Comments
 
LVL 16

Expert Comment

by:Imran Javed Zia
ID: 35198168
Hi,
you can use RowUpdated event if you want to get row index after update the object and here you can get changed values

alternatively you can use RowUpdating event and get can use e.rowindex to get grid row and then get related object and manually call update method.
Thanks
0
 

Author Comment

by:suroma
ID: 35199135
The datagridview does not have those events. The column being updated is a checkbox column.
0
 
LVL 16

Accepted Solution

by:
Imran Javed Zia earned 500 total points
ID: 35199165
Sorry, I posted for GridView,
Anyhow you can use checkbox click event too for this purpose
0
 

Author Comment

by:suroma
ID: 35378990
OK I will. I should be able to check it out in a few days as this task has slipped down the priorities. Thanks.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
VB.NET 1 22
C# Gridview 1 32
SQL Query Help Top 1 and Distinct? 6 26
vb.net cycle through results of a sql query and capture variables 3 11
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question