Xamarin.Helpers | Several Xamarin-based classes
kandi X-RAY | Xamarin.Helpers Summary
kandi X-RAY | Xamarin.Helpers Summary
Several Xamarin-based classes I keep using, reusing, coding and recoding every time I create a new app
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of Xamarin.Helpers
Xamarin.Helpers Key Features
Xamarin.Helpers Examples and Code Snippets
Community Discussions
Trending Discussions on Xamarin.Helpers
QUESTION
When I create a new Xamarin.Forms project in Visual Studio 2017, in the project properties I can't target any other framework than
- .NET standard 1.0
- .NET standard 1.1
- .NET standard 1.2
- .NET standard 1.3
- .NET standard 1.4
- .NET standard 1.5
- .NET standard 1.6
- .NET standard 2.0
I'm trying to use a nuget package targeting .NET Framework 4.6.1 and it doesn't load because of that.
I have a warning when i add that package :
The package CHU.Xamarin.Helpers 1.0.0.1 has been restored using '.NETFramework,Version=v4.6.1' instead of target framework of the project '.NETStandard,Version=v2.0'. The package might not be totally compatible with your project.
Is there a way to target .NET Framework 4.6.1 in the project ?
If i add the nuget package anyway, i've got an error saying it is not compatible with monoandroid71 :
The package CHU.Xamarin.Helpers 1.0.0.1 is not compatible with monoandroid71 (MonoAndroid,Version=v7.1). The package CHU.Xamarin.Helpers 1.0.0.1 handles : net (.NETFramework,Version=v0.0)
The error messages are translated from French so might differs from english counterpart
...ANSWER
Answered 2019-Sep-05 at 18:23NOTE: None of the following answers "how to target .NET Framework 4.6.1 for a Xamarin.Forms project". If you really, truly, need to know how to do that, and know what you are doing, and why, then search elsewhere - doing so is an advanced topic, and is no longer recommended. For cross-platform projects, stick with a .NET Standard version.
In this case, despite the question title, doing so is not the solution. Keep reading for more details.
I'm trying to use a nuget package targeting .NET Framework 4.6.1 and it doesn't load because of that.
Actually, it does load. It gives you a warning. You can probably ignore that Framework vs Standard warning - I've been ignoring a Framework 4.6.1 vs Standard 2.0 warning for over a year, without problem.
error .. saying it is not compatible with monoandroid71
This is the real problem that is stopping you.
Is there a packages.config
file? If so, open it in a text editor, and search for monoandroid71
. If present, then yes, this is the problem -
The packages.config mechanism contains an outdated "hint", OR you ARE targeting an older Android version, that is not compatible with the nuget you wish to use - as the message says.
Possible fix:
- Target Android 8.0 or higher. In your Android project (e.g. if you named your Xamarin Forms project "App1", look in solution for the project labeled "App1.Android") / Properties / Application / Compile using Android version (Target Framework) / select Oreo or Pie.
- Update all nugets to latest.
- If packages.config still mentions monoandroid71, then you have outdated "hints".
Different ways to fix outdated hints in project.config. Do ONE of the following:
- Rt-click on project.config in Solution pane, select "Migrate to PackageReferences". This newer mechanism doesn't rely on hints.
- OR Delete project.config. Add the nugets again.
- OR Manually edit project.config. Change all targetframework=monoandroidXX to be the same - whatever the highest number you find in the file. Probably monoandroid81 or monoandroid90.
- OR Start all over. Latest VS 2017 version OR VS 2019. Either works fine for this purpose. New project / C# / Mobile App Xamarin Forms. Copy your source files (.cs, .xaml) to the new projects - DON'T use your old .csproj or package.config. The goal is to use all the latest build options, including PackageReferences.
QUESTION
I have issues with Xamarin in Visual studio 2017 15.8.0 Preview 4 (And all previous builds)
I have a Xamarin forms project with a Android Project and a UWP project, if I change the startup project to UWP and try to compile I get this error
Error Failed to resolve assembly: 'FoosballXamarin.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' FoosballXamarin.UWP ...\Views\LoginPage.xaml
And the XAML itself will give me errors on these lines
...ANSWER
Answered 2018-Jul-25 at 21:54Based on the errors you're seeing, I'm going to guess you have this configured as a shared project (not PCL/.netstandard). If that's the case, simplify the lines in the XAML file to:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install Xamarin.Helpers
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page