OnEditEnded PropertyGridEditEndedEventArgs OldValue and NewValue always have old values

7 posts, 0 answers
  1. Greg Horvath
    Greg Horvath avatar
    9 posts
    Member since:
    Aug 2009

    Posted 26 Jan 2015 Link to this post

    When OnEditEnded is fired the e.OldValue and e.NewValue don't seem to have the correct value. They both always have the old value. I need to be able to see if the value has changed to update the a dirty data flag in my application. Is there any way to do this? Thanks
  2. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1128 posts

    Posted 29 Jan 2015 Link to this post

    Hello,

    I have prepared a sample test project, but I did not have any success in reproducing this behavior. I am attaching it for your reference. Can you please confirm whether you can notice any related difference between your approach and mine?

    Regards,
    Ivan Ivanov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for WPF is Visual Studio 2017 Ready
  4. Greg Horvath
    Greg Horvath avatar
    9 posts
    Member since:
    Aug 2009

    Posted 30 Jan 2015 in reply to Ivan Ivanov Link to this post

    This approach is essentially what I am doing and I am seeing the same behavior in your sample project. I select the first row in the grid view, then go to the Name property in the property grid. I change the value from "Liverpool" to "Test" and in the event handler the old value still says "Liverpool". You can see this in the immediate pane in the screen shot below.


  5. Greg Horvath
    Greg Horvath avatar
    9 posts
    Member since:
    Aug 2009

    Posted 30 Jan 2015 in reply to Greg Horvath Link to this post

    Looks like my pasted image referenced in last reply did not show up. It is attached.
  6. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1128 posts

    Posted 04 Feb 2015 Link to this post

    Hi,

    Please excuse me for the delayed reply. I am afraid that I am still not able to reproduce the issue. The only approach that results in the same OldValue and NewValue on my side is when the edited property is not changed. I guess that I am missing something, so I am attaching a video

    Regards,
    Ivan Ivanov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  7. Greg Horvath
    Greg Horvath avatar
    9 posts
    Member since:
    Aug 2009

    Posted 04 Feb 2015 in reply to Ivan Ivanov Link to this post

    I noticed from your video that your navigating using the mouse only. E.g. clicking the next cell when you finished editing. The issue appears to only happen if you tab off the current cell being edited. 
  8. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1128 posts

    Posted 05 Feb 2015 Link to this post

    Hi,

    You are right. Tabbing out results in raising the event with wrong arguments. I am adding 1000 Telerik points to your account in accordance to this bug report. We will do our best to fix it with the incoming Q1 release.

    Regards,
    Ivan Ivanov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top
UI for WPF is Visual Studio 2017 Ready