1

Is there a tutorial that tells how to write a profile for mono 3.0 so that I can use it with Microsoft Visual studio 2010 ? The reason behind the same is that my application makes use of a Binding List and when I try to run in Mono , I get this error : ** (WindowsFormsApplication2.exe:608): WARNING **: The class System.ComponentModel.BindingList`1 could not be loaded, used in System, Version=4.0.0.0,

or in case a profile is already written , can you please share the same

2 Answers2

10

I created my own 4.5 Profile for Mono 3.0.1 Beta for VS 2012 on a Windows 8 64-bit machine based on this.

  1. Create a folder called Mono
  2. Inside this folder, create another folder called RedistList
  3. Copy C:\Program Files (x86)\Mono-3.0.1\lib\mono\4.5 into folder Mono
  4. Inside folder RedistList, create a file called FrameworkList.xml
  5. Paste the following into file FrameworkList.xml:
    <?xml version="1.0" encoding="utf-8"?>
    <FileList Redist="Mono_3.0.1" Name="Mono 3.0.1 Profile" RuntimeVersion="4.5" ToolsVersion="4.5"></FileList>
  1. Navigate to C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\ .NETFramework\v4.5 and create a folder called Profile
  2. Copy your folder Mono into folder Profile
  3. Add the following to registry to stop Visual Studio asking for installation of this profile:

    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\.NETFramework\v4.0.30319\SKUs\.NETFramework,Version=v4.5,Profile=Mono
    

Now you should be able to select and compile against this profile. This steps might be slightly different on 32-bit machines (see link at top).

Bjørn Madsen
  • 378
  • 2
  • 17
Dresel
  • 2,375
  • 1
  • 28
  • 44
  • No problem - if it fits to your question, i'll be glad if you mark it as answer :) – Dresel Nov 23 '12 at 13:17
  • This should be the accepted answer. I'ts kinda tricky to know that you have to add the key to "v4.0.30319" instead of creating a key "v4.5" - Works well for me. thanks – boop Jan 24 '15 at 21:39
1

You should play with the MONO_LOG_LEVEL and MONO_LOG_MASK environment variables (especially, consider using "asm" value for the latter). All is explained here: http://www.mono-project.com/Logging_Runtime_Events

This will give you enough insight of what is happening.

On a side note, why do you need Mono in Windows? Unless you're doing very advanced things (such as embedding mono), I recommend you to only use Mono in Unix-like OSs, like Mac or Linux, which is where it shines. Mono in Windows is sub-standard quality because in Windows you have the .NET runtime from Microsoft anyway.

knocte
  • 16,941
  • 11
  • 79
  • 125
  • THanks for the information Knoc, A lot of our users want to migrate to MAC and we have some applications developed in Dot net which we want to reuse to maximum possible extent in Mac , hence the need for the profiler although as you pointed out we will continue to develop in windows but target mac – AnandNagarajan111 Nov 23 '12 at 13:12
  • if you want to migrate those .NET apps to Mac then you should test Mono in Mac, not Mono in Windows – knocte Nov 23 '12 at 14:32