views:

65

answers:

2

I created a C# .NET 3.5 project with Visual Studio 2010, add some classes and forms and close it. After that I open the project with Monodevelop 2.2.1 and add some additional stuff and close ist again. Now when I reopen the project with Visual Studio 2010, the project conversion manager pops up and wants to convert the project. I analysed the project files and the differences are only the following two lines:

Visual Studio 2010:

<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
...
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
...

Monodevelop 2.2.1:

<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"&gt;
...
    (missing)
...

Do you have any suggestions how to avoid this? Like how to tweak Monodevelop to write the project files Visual Studio wants to read or disable the conversion agent or converting silently in the background.

And please no complaints about the tool chain ;) It must be like that.

+2  A: 

I recommend you try MonoDevelop 2.4. MonoDevelop 2.2 predates VS 2010.

mhutch
+1  A: 

I have been used to such issues for a long time. My rule of thumb is to make all project level changes (that will modify csproj files) in Visual Studio, while file level changes can be made in both MonoDevelop and Visual Studio without a problem.

It seems that MonoDevelop does not make use of MSBuild script in a way compatible to Visual Studio.

You may try out its latest build, but I don't think it will change much in a short period of time.

Lex Li
with Visual Stdio 2008 there I did not have these problems, but with v10 I am currently doing exactly what you suggested... I though that maybe there is another way. Perhaps they really solved it with 2.4.
Danvil
I have been using Visual Studio 2010 for a while, but never used Visual Studio 2008 along with MonoDevelop. Maybe you are right that MD works fine with VS2008. But definitely Visual Studio 2010 and MSBuild 4 make a lot of changes, so MD and XBuild need some time to adapt to them.
Lex Li