Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error in building and running Xamarin iOs application in visual studio 2015 preview

I am the newbie in Xamarin Cross Platform development. I am using Visual Studio 2015 Preview for development. I created the new solution for mobile app and it is working correct for both Droid and Windows phone. But after successful connection with iOs Build host I got the error when I build the iOs App like -

Xamarin.iOS does not support running or debugging the previous build version of your project.Please ensure your solution builds before running or debugging it.

And also when I click on View iOS Simulator I got build host error. Error: Build version problem. it will show the build version problem.

Please tell me the solution for this.

like image 773
Codelord Avatar asked Feb 18 '15 09:02

Codelord


People also ask

Does Visual Studio 2015 support Xamarin?

We're excited to announce same-day Xamarin support for Visual Studio 2015, including Visual Studio 2015 Community Edition, MSFT's free IDE for non-enterprise apps.

How do I show Xamarin preview?

You can open the XAML Previewer by clicking the arrows on the split view pane. If you want to change the default split view behavior, use the Tools > Options > Xamarin > Xamarin. Forms XAML Previewer dialog. In this dialog, you can select the default document view and the split orientation.


1 Answers

Most common cause of those symptoms

The most likely cause of this issue is the following known bug: https://bugzilla.xamarin.com/show_bug.cgi?id=25811

Explanation

The problem in that bug is that the Xamarin.Forms template is using a bad default setting for the iOS project in Visual Studio's configuration manager.

The configuration manager works by telling Visual Studio which projects you want to be built and/or deployed at the same time in the configuration you're using at the time.

So for example; when you build your Android project in Forms, the configuration manager makes sure that the shared project is included; otherwise it wouldn't work, or you'd have to build it separately or etc. etc. (i.e. a real pain.)

Normally, Visual Studio doesn't have a way to automatically "know" which project(s) you want to include in all your configurations; you'd have to tell it to include (some library) with (some app); etc. manually.

How to fix it

Screencast: http://www.screencast.com/t/zLoQOpEn

  1. Go to "Build -> Configuration Manager"
  2. Select the configuration(s) you wish to adjust, (e.g. Debug | iPhoneSimulator, Release | iPhone)
  3. Make sure your shared library project(s) are included with the platform-specific configurations. (You can ignore the greyed-out 'Deploy' checkboxes, those are handled automatically)

Why this is a bug

So this isn't a bug in that the configuration manager isn't working correctly for iOS projects, but that the Forms template is using a bad default setting for the iOS projects when you create a new app. It should "know" to include the shared project in the iOS configurations by default.

like image 196
user62171 Avatar answered Oct 26 '22 23:10

user62171