Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Add xamarin.ios and xamarin.android to portable class library

When adding a new portable class Library project using visual studio 2012, in the add target window I can't find xamarin.ios and xamarin.android.

like image 805
kadben Avatar asked Jun 07 '13 08:06

kadben


Video Answer


1 Answers

Here is what you need to do. Follow the thread here, if you hit any issues.

  1. Open an explorer window to C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable\v4.0\Profile\Profile104\SupportedFrameworks
  2. Create a new file in the folder named 'MonoTouch.xml' and put in the following content

    <?xml version="1.0" encoding="UTF-8"?>
    <Framework MinimumVersion="4.0" MaximumVersion="*" Profile="*" Identifier="MonoTouch" DisplayName="MonoTouch"/>
    
  3. Create a new file in the folder named 'MonoAndroid.xml' and put in the following content

    <?xml version="1.0" encoding="UTF-8"?> 
    <Framework MaximumVersion="*" MinimumVersion="1.6" Profile="*" Identifier="MonoAndroid" DisplayName="Mono for Android"/>
    
  4. Restart Visual Studio if it is still open

  5. The options for MonoTouch and Mono for Android should now be available in the PCL enter image description here
like image 64
Mike Stonis Avatar answered Sep 30 '22 17:09

Mike Stonis