Quantcast
Channel: simplemvvmtoolkit Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 20

Edited Unassigned: ViewModelDetail EndEdit not respecting attributes [1618]

$
0
0
Tony,

I'm built a Silverlight 5 application using Telerik's Data Access component. I recently added a detail view using the ViewModelDetail template. Adding a new record works fine, but editing an existing one throw the following error __the field OpenAccessGenerated is read-only__. The response from the Telerik Support is as follows...

Thank you for the provided sample, we were able to find the causes of the issue. It seems that the Silverlight MVVM template which you are using has a method EndEdit() which doesn't respect the attribute in the class generated by the RIA Service. The property OpenAccessGenerated is a propery descriptor used by the metadata in the OpenAccessContext and is generated by the RIA Service with these attributes:

```
[DataMember()]
[Display(AutoGenerateField=false, AutoGenerateFilter=false, Description="OpenAccess Key", Name="-ID-")]
[Editable(false)]
[ReadOnly(true)]
[RoundtripOriginal()]
public string[] OpenAccessGenerated
```

Somehow the EndEdit() method, which is called in the RadGridView_PreparedCellForEdit() method, didn't respect these attributes and try to update the value of the property. Also this method, which is inherited from the abstract class SimpleMvvmToolkit.ViewModelDetailBaseCore is not virtual and cannot be overwritten.

I have a sample app that I can send you... I would attach but i's like 24 m.

MM


Viewing all articles
Browse latest Browse all 20

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>