Specifically the error occurs in the Resources.Designer.cs
:
Error 2 The namespace \'ModulusFE\' already contains a definition for \'Sto
if you have 2 versions of any of your code file (*.cs, *.vb etc.) inside your "app_code" folder then you will get this error because dot net would include both the files in your project and will get 2 different implementations of the same class (because of same name in 2 versions of same code file in app_code folder)
I've had this problem, too, and it was because I created a new namespace, but the parent namespace contained a class with the same name.
Me too got this error, When I change my WPF project's Target Framework to Framework Version 4.0 Client Profile -> Framework 4.0. It's solved by itself.
I had an xaml file with the following definition
<Window x:Class="mm2.Views"
.etc..
/>
mm2.Views
was the name of a namespace in my app.
To fix it, I correctly renamed the xaml object:
<Window x:Class="mm2.Views.RecordedTracks"
.etc..
/>
I had a similar problem (Universal project, Visual Studio 2015), I solved it with the following changes:
In App.xml.cs was (it was ok):
namespace Test.Main {
Wrong, old version of App.xml:
x:Class="Test.Main"
Good, new version of App.xml:
x:Class="Test.Main.App"
Looks like a bug in VS code's OmniSharp.
Solution for me was to execute command "Restart OmniSharp".
Just do: - ctr shift P - type "Restart OmniSharp" .. hit enter
This fixed it for me.