Entity Framework 4.0 Autogenerated Classes not marked as Serializable?

The purpose of T4 template is allow you to customize. Customize it fearlessly! You are not only encouraged to customize template, but also the edmx file that your template is based on.

See this http://blogs.msdn.com/adonet/archive/2010/03/05/updated-data-model-designer-extension-starter-kit.aspx.


Yes you can modify the template. Look at Adding DataMember DataContract attributes in Entity Framework POCO Template for exactly what you need to do to fix your template. Look specifically at the WriteHeader function in the template.


Related Questions