android - 错误 CS0103:当前上下文中不存在名称“资源”
问题描述
使用Xamarin
,当我编译我的项目时,我得到一堆错误,就像标题中的错误一样。所有的错误错误都像这样在线发生:
LINE: var buttonLogin = FindViewById<Button>(Resource.Id.buttonLogin);
ERROR: error CS0103: The name 'Resource' does not exist in the current context
然而,这只是thrown
通过compiler
,代码没有下划线的语法问题,我也可以 f12Resource.Id.buttonLogin
并找到为他的资源生成的代码。
代码工作并且看起来不错,但编译器不会停止抛出错误。
解决方案
推荐阅读
- oracle - Oracle 11g 可能的最大语句长度
- node.js - 全局变量未更新
- android - Firebase 针对修改后的 APK 和 MITM 攻击的安全性
- angular - Communication b/w Angular Components: Using @Input, @Output and Sharedservice. Which one to use?
- java - 无法从其他活动调用 RecycleView
- c - CUDD Binary Decision Trees. Linking to libcudd.a
- wordpress - Confusing about owner Wordpress website permission
- python - array[...,list([something]) 是什么意思?
- python - 如何在 Mac 上执行我的 python 脚本的自动启动?
- r - 在 R 中应用逐年分段回归