Page 1 of 1

How to auto-generate the WCF RIA [Key] attribute

Posted: Mon 16 Jan 2012 11:58
by agrei1
Hi,

I posted this in the wrong forum earlier so am re-posting it here.

Using Entity Developer for nHibernate, is there a way to have the "Key" attribute automatically placed before the primary key properties in all my entities? I've set the "Validation Framework"="DataAnnotations" already. Note that currently the "Required" attribute is added to primary keys automatically but the "Key" attribute isn't.

The reason I want this is that Silverlight WCF RIA domain services needs it. I could add it manually but that's a bit of a hassle.

Thanks

Posted: Thu 19 Jan 2012 15:17
by Shalex
Thank you for your report. We will post here when the issue is fixed.

Posted: Tue 24 Jan 2012 16:32
by Shalex
The bug with generating System.ComponentModel.DataAnnotations.Key() attribute for Primary Key columns is fixed. We will post here when the corresponding build of Entity Developer is available for download.

Posted: Fri 27 Jan 2012 14:18
by Shalex
New build of Entity Developer 4.2.120 is available for download now!
It can be downloaded from http://www.devart.com/entitydeveloper/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=23252 .