代码之家  ›  专栏  ›  技术社区  ›  Danvil

Using Mono 2.2.1 and Visual Studio 2010 simultaneously

  •  2
  • Danvil  · 技术社区  · 14 年前

    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">
    ...
        (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.

    3 回复  |  直到 14 年前
        1
  •  1
  •   Lex Li    14 年前

    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.

        2
  •  2
  •   Mikayla Hutchinson    14 年前

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

        3
  •  0
  •   Community Ian Goodfellow    7 年前

    使用 MonoTools for Visual Studio , which lets you run and debug your app on Mono (instead of .NET) under Visual Studio.

    The extension is for VS2010, but can easily be added to VS2012 .

    Note that MonoTools appears to have been deprecated, but it works fine with VS2010 and VS2012 without resorting to another IDE. It's the easiest way to run your VS projects under Mono, and provides a great debugger interface for testing on Linux and OSX without leaving Windows.