New Xamarin.Forms project does not build Android project (missing resources)
#8,809 opened on 2019/12/09
Repository metrics
- Stars
- (5,644 個のスター)
- PR merge metrics
- (30d に merged PR はありません)
説明
This issue has been moved from a ticket on Developer Community.
Starting a new Xamarin.Forms project in the latest Visual Studio (and Visual Studio for Mac) gives an issue in the Android project. A clean project does not want to build.
resource style/Theme.AppCompat.Light.Dialog (aka com.companyname.xxx:style/Theme.AppCompat.Light.Dialog) not found. xxx. Android
resource style/Theme.AppCompat.Light.DarkActionBar (aka com.companyname.xxx:style/Theme.AppCompat.Light.DarkActionBar) not found. xxx. Android
failed linking references. xxx. Android
style attribute 'attr/windowNoTitle (aka com.companyname.xxx:attr/windowNoTitle)' not found. xxx. Android
style attribute 'attr/windowActionBar (aka com.companyname.xxx:attr/windowActionBar)' not found. xxx. Android
style attribute 'attr/colorPrimaryDark (aka com.companyname.xxx:attr/colorPrimaryDark)' not found. xxx. Android
style attribute 'attr/colorPrimary (aka com.companyname.xxx:attr/colorPrimary)' not found. xxx. Android
style attribute 'attr/colorAccent (aka com.companyname.xxx:attr/colorAccent)' not found. xxx. Android
style attribute 'attr/colorAccent (aka com.companyname.xxx:attr/colorAccent)' not found. xxx. Android
style attribute 'attr/windowActionModeOverlay (aka com.companyname.xxx:attr/windowActionModeOverlay)' not found. xxx. Android
Original Comments
Visual Studio Feedback System on 11/27/2019, 01:45 AM:
Bart on 11/27/2019, 02:18 AM:
Update:- Opened manifest to check the min and target version.- Moved up all Xamarin project folders one level so they are on the same level as the rest of the solution. Cleaned solution, manually deleted all bin and obj folders as well and did rebuild.First time I got an error on:"obj\Debug\90\xx.Android.dll;obj\Debug\90\xx.Android.dll" is an invalid value for the "OutputAssembly" parameter of the "Csc" task. Multiple items cannot be passed into a parameter of type "Microsoft.Build.Framework.ITaskItem".Rebuild one more time and only have warnings now.<br>Warning The preprocessor token 'outputfilename' has been given more than one value. Choosing 'xx.Android.dll' as the value. xx.Android <br>Warning The preprocessor token 'filename' has been given more than one value. Choosing 'xx.Android.csproj' as the value. xx.Android <br>Warning The preprocessor token 'fullpath' has been given more than one value. Choosing 'C:\Bart\Code\yy\src\xx.Android' as the value. xx.Android <br>Warning The preprocessor token 'assemblyname' has been given more than one value. Choosing 'xx.Android' as the value. xx.Android <br>Warning The preprocessor token 'rootnamespace' has been given more than one value. Choosing 'xx.Droid' as the value. xx.Android <br>Warning "obj\Debug\90\xx.Android.dll;obj\Debug\90\xx.Android.dll" is an invalid value for the "OutputAssembly" parameter of the "Csc" task. Multiple items cannot be passed into a parameter of type "Microsoft.Build.Framework.ITaskItem". xx.Android <br>Moving up the Xamarin folders one level reduced the Android folder path from 99 to 80 characters, with another 44 characters for the csproj name.
Original Solutions
(no solutions)