Cannot set build function for GoogleServiceJson

I am working with Xamarin-Android to create an application, so I need to install Build Action for my google-services.json file, but there is no property like GoogleServicesJson, and when I try to just write it, it shows me an exception:

An exception of type 'System.Runtime.InteropServices.ExternalException' was thrown.

I tried to save and then restart Visual Studio, but this did not solve the problem.

If you know how to solve this problem, please help me! :)
What file do I click on

+8
source share
8 answers

GoogleServicesJson Xamarin.GooglePlayServices.Basement.targets.

Xamarin.GooglePlayServices.Basement, , Xamarin.GooglePlayServices.Gcm Xamarin.Firebase.Messaging, , .

, Basement , .csproj Xamarin.GooglePlayServices.Basement.targets GoogleServicesJson :

.csproj :

  <Import Project="..\packages\Xamarin.GooglePlayServices.Basement.42.1001.0\build\MonoAndroid70\Xamarin.GooglePlayServices.Basement.targets" Condition="Exists('..\packages\Xamarin.GooglePlayServices.Basement.42.1001.0\build\MonoAndroid70\Xamarin.GooglePlayServices.Basement.targets')" />
+20

"Xamarin.GooglePlayServices.Basement" GoogleServiceJson . , Xamarin , .

+11

1- :

Xamarin.Firebase.Common

Xamarin.Firebase.Config

Xamarin.Firebase.Iid

Xamarin.GooglePlayServices.Base

Xamarin.GooglePlayServices.Basement

Xamarin.GooglePlayServices.Tasks

2 - 3- google-services.json → → build : GoogleServicesJson

+5

:

enter image description here

enter image description here

+1

GoogleServiceJsom Xamarin.GooglePlayServices.Basement. , ,

0

Visual Studio . :)

0

, , Build, , Mac enter image description here

PS Google-Services.json "". "", , , ""

enter image description here

0

When using AppCenter, I did not add the App center and App Center Push packages to the Android Dependencies folder. After adding GoogleServicesJson immediately appeared

0
source

Source: https://habr.com/ru/post/1671824/


All Articles