0

We recently upgraded to MVC2 and SharpArchitecture 1.6. Our models are all in our Project.Core project, while resources are in our Project.Web project. We can't reference the resource files in Core , as that would create a circular dependency.

We want to use Data Annotations on the model - is there a way to access the resource files so we can have localized messages?

1 Answers1

0

Why not extract in a stand alone project all your resources? you can then reference them from every project without the circular reference. From dataannotaion you link them like this

[Required(ErrorMessageResourceType = typeof(Resources.Validations), ErrorMessageResourceName = "Required")]
Iridio
  • 9,213
  • 4
  • 49
  • 71