【发布时间】:2016-09-29 21:10:28
【问题描述】:
1) 每当我运行我的代码时,“。”标签“action”中的appwidget.action之间变成了“,”。是什么导致了问题?谁能帮帮我?
在运行代码之前,
<receiver android:name="com.example.newstart.practice.Widget" >
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE"/>
</intent-filter>
<meta-data
android:name="android.appwidget.provider"
android:resource="@xml/widget_stuff" />
</receiver>
运行代码后,
<receiver android:name="com.example.newstart.practice.Widget" >
<intent-filter>
<action android:name="android.appwidget,action.APPWIDGET_UPDATE"/>
</intent-filter>
<meta-data
android:name="android.appwidget.provider"
android:resource="@xml/widget_stuff" />
</receiver>
它会自动变为“,”并显示错误:
Error:(228) Tag <action> attribute name has invalid character ','
2) 在这个错误下也会显示这个错误-
错误:任务 ':app:processDebugResources' 执行失败。 com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\ASUS\AppData\Local\Android\sdk\build-tools\23.0.3\aapt.exe'' 以非零退出值 1 结束
【问题讨论】:
-
你用什么运行代码?
标签: android compiler-errors android-manifest action receiver