Adding Xamarin.Forms Package Issues

1

I'm starting some projects with Xamarin Studio, I'm having some problems and I still can not solve it. It always appears these 2 errors, I looked at a solution on stackoverflow.com, but the solutions given there did not solve my problem and since I did not find anything like it, I decided to post here. Right at the beginning of my application,

using Xamarin.Forms;
  

The type or namespace name 'Xamarin' could not be found (are you missing a directive or an assembly reference?) (CS0246)

public class App : Application
  

The type or namespace name 'Application' could not be found (CS0246)

The solution to solve this is routine taken from stackoverflow.com

  • Select the project in the Solution tab
  • Select "Project" along the top menu
  • Select "Add Nuget Packages ..."
  • Do a search for "Xamarin.forms"
  • Add "Xamarin.forms" to that project
  • The problem with doing this is that it can not add the Xamarin package, it has another problem:

      

    Could not install package 'Xamarin.Forms 1.3.3.6323'. You are trying to install this package into a project that targets 'portable-Profile78', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.

        
    asked by anonymous 05.10.2015 / 17:11

    1 answer

    1

    First the version of the package you are trying to install is very old, try installing the latest one ( 1.5.0.6447 ). Another item is to check if the profile you selected in the project or the framework you are using is compatible:

    • Which version of Xamarin Studio are you running?
    • What version of Xamarin.Android or Xamarin.iOS is this project using?
    • If it is a PCL library, which profile is this library set up to use?

    If you are on Windows, make sure you have installed support for Portable Libraries and Visual Studio 2013 or later ( see how to install here - link in English ). If you needed to install the media and had already installed Xamarin before, you will need to reinstall the media.

    In addition, the referenced package supports only the following platforms: Portable .NET 4.5, Windows Phone Silverlight 8.0, Xamarin.Android, Xamarin.iOS and Xamarin.iOS (Classic); not including support for Silverlight 5.0. You can not have other platforms or larger versions configured in your project to use this package.

        
    08.10.2015 / 22:35