【问题标题】:Firebase Cloud Messaging with Xamarin AndroidFirebase 云消息与 Xamarin Android
【发布时间】:2016-11-18 09:50:04
【问题描述】:

我正在尝试使用newly released Firebase Messaging Nuget for Android 参考this sample,上面写着:

确保您已下载自己的配置(google-services.json 文件)文件并使用“GoogleServicesJson”构建操作将其添加到您的应用项目中。

我已经下载了文件并将其添加到项目中,但无法执行 GoogleServiceJson 类型的构建操作,我缺少什么?

因为我遇到了编译问题 if (GetString(Resource.String.google_app_id) == "YOUR-APP-ID") 因为应用程序无法找到名为 google_app_id 的资源字符串。

有人可以帮我了解缺少什么吗? 谢谢

【问题讨论】:

标签: xamarin.android firebase-cloud-messaging


【解决方案1】:

将 google-service.json 文件添加到您的项目之后。 选择 google-service.json 文件并转到文件的属性。 在“属性”窗格中,将构建操作设置为 GoogleServicesJson(如果未显示 GoogleServicesJson 构建操作,请保存并关闭解决方案,然后重新打开它。

enter image description here

【讨论】:

    猜你喜欢
    • 2018-10-25
    • 1970-01-01
    • 2016-12-05
    • 1970-01-01
    • 1970-01-01
    • 2021-07-06
    • 2021-11-21
    • 1970-01-01
    • 2016-10-05
    相关资源
    最近更新 更多