How to add a reference to a cross platform app?

I am trying to add a reference (AWS SDK) to a cross platform app in Visual Studio, but I only see options to either add it to the ios or the android version (because the part of the app that is cross platform doesn't have an thing for references in the solution explorer).
Is there a way to be able to use the reference in the cross platform code or do I have to write code twice for android and ios versions?

Tagged:

Best Answer

  • mrvladimirmrvladimir US
    Accepted Answer

    You can add references to the Android and iOS versions and they will be visible to the cross platform form code. You might have to build before the intellisense picks up the dependencies.

Answers

  • mrvladimirmrvladimir USMember
    Accepted Answer

    You can add references to the Android and iOS versions and they will be visible to the cross platform form code. You might have to build before the intellisense picks up the dependencies.

  • mikeacostamikeacosta USUniversity ✭✭✭
    > @mrvladimir said:
    > Is there a way to be able to use the reference in the cross platform code or do I have to write code twice for android and ios versions?

    Yes, if it's a portable class library. It sounds like your shared code is not a PCL.
Sign In or Register to comment.