Hello,
I want to help you, but I need some more information about what behavior you are looking for.
In the sample that you send me I'm able to enter value and apply it.
Thanks,
George
Thank George for your answer. I'll try to provide more details.
Use case:
1. User set cell in edit mode then enter new value and stay cell in edit mode.
2. Update source(binded property) from outside but stay cell in edit mode with user entered new value.
3. User can leave edit mode by:
- press Enter key to apply entered new value (and rewrite updated value from outside);
- press Escape key to revert entered new value and apply updated value from outside;
The test project "DiscardUpdateCellInEditMode" which I've attached contains window. Window contains xamDataGrid with one record and one column callled "Name". DataSource binds to collection called "Persons" of "Person" objets with single property "Name". "Persons" collection initialized by one "Person" instants(property "Name" was set to "Person name"). Also the window contains TextBox UI Element. Text from TextBox is set to Person's Name property every 5 sec.
So initialization data is following when we start test project:
1. The collection Persons contains one Person instant with Name = "Person name" => xamDataGrid cell value is also equal to "Person name".
2. TextBox.Text = "New Cell Value".
3. In 5 sec Person.Name will set to TextBox.Text("New Cell Value") => xamDataGrid cell value also will set to TextBox.Text("New Cell Value").
Current behavior of the test project:
1. User run application set cell in edit mode and enter new value "User Entered Value" and do not leave edit mode.
2. Cell will stay in edit mode BUT ENTERED VALUE("User Entered Value") WILL UPDATED BY "New Cell Value" in 5 sec.
I expected following behavior of the test project:
1. The same
2. Cell will stay in edit mode AND VALUE WILL STAY "User Entered Value" in 5 sec. The user can press Escape key to leave edit mode and apply value "New Cell Value" OR press Enter key to leave edit mode and apply "User Entered Value"(and set this value to Person.Name).
So the goal is "Supress update the value of ValueEditor when cell is in edit mode and source(in our case Person.Name) is updated outside".
Thank you in advice.