Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Datagridview row not accepting changes

Posted on 2014-09-24
2
Medium Priority
?
210 Views
Last Modified: 2014-09-25
Hello,

I have a datagridview.  If the user is editing a row and then clicks to another control when they return to the same row then any changes they make are rejected i.e if the change a value it immediately changes back to the value prior to moving from the row,  If they click to another row and then return to the original then they are able to edit it normally.

Please could anyone explain this and suggest a solution.

Thanks
0
Comment
Question by:Petermcg001
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 40

Accepted Solution

by:
Jacques Bourgeois (James Burger) earned 2000 total points
ID: 40344262
You might have an event procedure that brings back the original value.

The first that comes to my mind is RowValidating that is usually used for such a purpose.

But there are so many events in that control that it can be another of them.
0
 
LVL 1

Author Closing Comment

by:Petermcg001
ID: 40344301
Thanks, your suggestion has pointed me in the right direction.  It turned out to be in the cell validating event.  I'd managed to include some code which was not assigned to a given cell index,.  I moved this and it works fine.

Thanks again.
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

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

What my article will show is if you ever had to do processing to a listbox without being able to just select all the items in it. My software Visual Studio 2008 crystal report v11 My issue was I wanted to add crystal report to a form and show…
A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

705 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