This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Hi, We have a basic system, split over 6 models. The issues is whenever we save a certain model, the designer sticks a "[System.CodeDom.Compiler.GeneratedCode("LightSpeedModelGenerator", "1.0.0.0")]" attribute in before the partial class of the unit of work. The compiler does not like this and give a "Duplicate 'System.CodeDom.Compiler.GeneratedCode' attribute" error. Manually removing this attributes solves it, but every time the designer is saved, the extra attribute is stuck in again. Below is the "model of work" classes from our 6 models. Any idea what we are doing wrong? Note that it doesn't see to generate the same error for the other models, just model 2. It also doesn't generate the attribute for model 4, 5 or 6 Thanks Model 1
Model 2 Has the error
Model 3
Model 4
Model 5
Model 6
|
|
|
You will need to customize the templates to avoid this behavior as the output is driven by the template files - we dont expect two seperated models to have the same output class name. Here is a post which details how you can customize the templates on a per project basis - http://www.mindscapehq.com/blog/index.php/2009/09/16/customising-lightspeed-entity-templates/ The line you want to remove is in DataContext.vm where the typed unit of work is generated.
|
|