<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Widget_demo</string>
<string name="action_settings">Settings</string>
<drawable />
</resources>
我在行<drawable />
中收到以下错误:
error: A 'name' attribute is required for `<drawable>`
答案 0 :(得分:0)
更改
<string name="app_name">Widget_demo</string>
<string name="action_settings">Settings</string>
<drawable /> // remove this
到
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Widget_demo</string>
<string name="action_settings">Settings</string>
</resources>
同时浏览文档
http://developer.android.com/guide/topics/resources/string-resource.html
答案 1 :(得分:0)
删除以下内容:
<drawable />