Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Portable Class Library assembly reference problems in MonoDroid and MonoTouch

I have problem in my project where I have PCL for .Net 4.5, Windows Phone 8, WinRT, MonoTouch and MonoDroid, when I try to build MonoDroid or MonoTouch project that have reference to that PCL errors are following:

*Error 1 The type 'System.Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.

Error 2 The type 'System.Enum' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.

I have done suggested command (sn -Vr *,b03f5f7f11d50a3a), but it didn't help. I am using the following profile:

C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.5\Profile\Profile78
like image 601
user2087302 Avatar asked Mar 01 '13 08:03

user2087302


1 Answers

If you set the compability to from .NET 4.5 to .NET 4.0.3 it will work.

like image 95
dna Avatar answered Jan 02 '23 21:01

dna