Forum Visual Studio

Referencing Xamarin.Mobile.dll not working properly

I have a weird situation. I downloaded the Xamarin.Mobile.dll and add a reference to it in my solution. However, when adding my 'using' clause, it can not find it (Xamarin.Contacts to be specific). Now here's the weird part; When I remove the reference to my solution, suddenly the 'using' clause works, as in the intellisense picks up the Xamarin.Contacts package, and I can use the classes in that package such as AddressBook, but when I go to compile the application, the IDE tells me that it can't find a reference to Xamarin.Contacts (which of course is because I removed it). To sum it up, if I add a reference to it, the IDE doesn't recognize it but it compiles, if I remove the reference, the IDE DOES recognize it, but it won't compile. I know this is a little confusing, but it's boggled my mind too. Anything suggestions would be appreciated!!


  • mhutchmhutch USMember, Xamarin Team Xamurai

    There's a known issue with Android projects where the code completion engine doesn't update after adding/removing a reference - it updates the next time the project is modified. You can work around it by closing and reloading the project after adding a reference.

  • Thank you very much! Worked like a charm.

Sign In or Register to comment.