Error checking on the MDriven models inside VS IDE - mdriven

I have a legacy system based on ECO III and now upgraded to MDriven. It works ok but there are quite a number of errors when I try to check for model error inside VS IDE:
The error messages look strange, I have no clue in what parts of the model caused the error...

Looks like there may be "ghost" classes with name "" in your model.
Scroll the model tree - do you see rows with only the class symbol but no name?
Should it have a name or should it be deleted?

Related

how can i fix this error for drumboiler example

How can I fix this error for drumboiler example?
It's kind of hard to answer questions without the model code, but based on the error with Cv.from_bar my guess is that you copied some code containing that from MSL (Modelica Standard Library - shown to the left in your package browser) for the boiler.
The likely corrections are:
Replace Cv.from_bar by Modelica.Units.Conversions.from_bar in the parameter-dialog of some component (sink?).
In Modelica text for this model add import Cv=Modelica.Units.Conversions;
If the models aren't directly from MSL they may contain errors.

TYPO3 object storage table does not exist - (tx_extbase_persistence_objectstorage)

I recently upgraded a relatively old System TYPO3 4.7 => 6.2.
I changed alot of namespaces/imports etc. and fixed stuff here and there. After the system was stable I made some changes in the extension builder and added some new fields.
I had to change some code in some files that threw errors but after that I was able to successfully save in the extension builder.
It added the correct classes,attributes and actions but now the system shows me this error:
1247602160: Table 'keepins_upgrade.tx_extbase_persistence_objectstorage' doesn't exist
Usually this error is related to models that are mapped incorrectly in the typoscript file but this seems different.. any suggestions?
Shot from the hip: you have one or more properties in your domain model which is annotated incorrectly - so it is read as a 1:1 relation to ObjectStorage, not a 1:n to a collection of another object. Or, less likely given your previous version, you've annotated a setter method or controller action so it requires an instance of ObjectStorage, but neglected to add PHPDOC that defines the true expected child type or is somehow else invalid or not connected to the right property.

EF broken after update database. A namespace cannot contain members such as fields or methods

I have researched this topic and pulled up a couple of hits that I thought might have helped me. So far I am still pulling out my hair over here because everything was fine until I added a field to a table in Azure and then tried to update my model.
Here's a short sitrep of what the problems have been and what I have done to solve them.
Problem 1
Compiling transformation: Metadata file 'C:\Program Files\VS2013\Common7\Tools..\IDE\Microsoft.Data.Entity.Design.dll' could not be found
Compiling transformation: Metadata file 'C:\Program Files\VS2013\Common7\Tools..\IDE\EntityFramework.dll' could not be found
I solved the problem by changing my global environment variable in advanced system properties to the correct location of these files, which in my case was : F:\Program Files (x86)\Common7\IDE
This is probably due to the fact that I just installed VS 2013 ultimate on my F drive; however, I have been developing on it successfully now for a week and never had a problem until now.
After this I run into problem 2:
Problem 2
A namespace cannot directly contain members such as fields or methods C:\Users\Adrian.Campos\Documents\Visual Studio 2013\Projects\ConsoleApplication2\ConsoleApplication2\Model1.cs 1 1 ConsoleApplication2
As you can see the problem is arising from my Model1.cs class. My .edmx file is named model1 (fyi)
I found some links that weren't of help to me since my error is coming from a different source than that of the links.
VS2012: My Entity Framework model doesn´t get included to my project output using InstallShield
A namespace cannot directly contain members such as fields or methods.
A namespace cannot directly contain members... + Type or namespace definition, or end-of-file expected errors
That last link seemed the most promising; however, it did not fix my problem. What I do not understand is how in the world did everything just blow up after I updated my model?
Has anyone else experienced this and fixed it?

problems were detected while vaidating & converting Ecore models. The names are not well formed for model objects in diagram

I tried to install the EMF plugin inside eclipse but some of the default Ecore diagram and EMF Generator Model projects were not available.
So downloaded a different eclipse installer for modelling i.e. Eclipse Modeling Tools (275 MB ) and found all the relevant model related & diagram based project now.
I have followed the same tutorial http://www.vogella.com/articles/EclipseEMF/article.html .
I was able to create the webpage model diagram & then the webpage.ecore file but then the webpage.genmodel the model generator file was giving errors like the ” names used in the diagrams for the objects are not well formed ” in webpage model diagram .
I googled for these errors which according to me mean that the names are not proper according to the given language for modeling constraints & no resolution to these errors were found.
then tried to ignore the errors and tried Generating the domain classes for java code, java code is generated but then the other following modules Create your model & Edit your model under Run your plugins category does not work further due to the previous errors on this link http://www.vogella.com/articles/EclipseEMF/article.html.
Please help me debug these errors
check if Name property is not null , you need to fill it
http://emftools.tuxfamily.org/wiki/doku.php?id=emfvb:quickstart
You need to set the name of Epackage and also prefix and URI
[1
[2

CA: Suppress results from generated code not working in VS2010 beta 2

I'm trying to run codeanalysis on an assembly that contains an entity model (edmx file). In project properties I have checked the "Suppress results from generated code" option, but I am still getting a lot of CA errors pertaining to the auto-generated EF code.
Has anyone experienced this? And is there a work-around?
Just put the attribute on your class definition.
But how to do it, since your file can get overridden any time. Use a separate file, since all generated classes are partial classes. Open a separate file, and write something like:
[GeneratedCode("EntityModelCodeGenerator", "4.0.0.0")]
public partial class YourEntitiesContextName : ObjectContext
{
}
This will skip code analysis on your particular generated class. StyleCop for instance is more smart and doesn't touch files that have .designer/.generated part in their name or regions that have generated word in their name.
Well, "Suppress results from generated code" really means "Don't look at types with GeneratedCodeAttribute". EF's code generator hasn't added this, historically (though I've suggested it to the team). But you can add it if you use custom T4.