Bug 17263 - Error message when adding a class to a PCL library
Summary: Error message when adding a class to a PCL library
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: General ()
Version: 1.10.x
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2014-01-15 17:42 UTC by abe
Modified: 2015-08-05 06:36 UTC (History)
9 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description abe 2014-01-15 17:42:34 UTC
As per http://forums.xamarin.com/discussion/comment/40680 :

I currently have a PCL project for shared code. I am adding classes here, but every time I add one I get the error:

> The reference "System" could not be added to the project. This wizard will continue to run, but the resulting project may not build properly.

I checked my target frameworks. I had .net4.5, silverlight 5, xamarin.android, and xamarin.ios. These seemed correct, since I am building an ios and android app. Nevertheless I added the two unchecked ones (Windows store apps, Windows phone 8). After this, adding classes to my PCL worked without the error message. So I removed the two target frameworks that I added and tried again, still no error message :)

BUT then I closed the solution and reopened, now with the same target frameworks that I started with, and this time I started getting the error message again :(

I am using VS2013. I'm not sure which version of xamarin I have (how can I tell?) I downloaded the latest one a few days ago from the website.
Comment 1 Shruti 2014-10-30 04:39:31 UTC
I have checked this issue in VS2013 with following steps mentioned below:
1. Create an Xamarin.Forms Portable project.
2. Add classes to the project.

I did not get any error after step 2 and after building the app.

Please let us know If I missed anything to reproduce this issue. If my steps are correct, Please check it once at your end and provide us your status.

Screencast : http://screencast.com/t/PqUvThdk

Environment Info  :

Comment 2 Rajneesh Kumar 2015-07-20 15:07:54 UTC
I have checked this issue with the latest stable build XVS 3.11.666 and observed that I am also not able to reproduce this. 

Screencast:  http://www.screencast.com/t/0k3ekxKpBnr

Could you please check this issue with the latest stable build XVS 3.11.666 and
let us know its working for you OR you are till getting same behavior ?


Environment Info:

Microsoft Visual Studio Professional 2013
Version 12.0.31101.00 Update 4
Microsoft .NET Framework
Version 4.5.50938
Installed Version: Professional
Xamarin   3.11.666.0 (ebae43a)
Visual Studio extension to enable development for Xamarin.iOS and
Xamarin.Android (5f55a9ef61c11b6ce0890bc91e4c71b1b92be214)
Visual Studio plugin to enable development for Xamarin.Android.
Xamarin.iOS (67b390d0d1bd741582cf7b7fd3ffea08583a3f83)
Visual Studio extension to enable development for Xamarin.iOS.
Comment 3 Udham Singh 2015-08-05 06:36:28 UTC
I'm closing this issue as no further information has been provided and we cannot reproduce similar issues with latest stable builds. Please feel free to reopen if the problem recurs.