use*_*325 19 java android android-gradle-plugin
我的android清单文件中有错误:
Error:Cannot read packageName from C:\Users\brandon\AndroidStudioProjects\MineDodge2\app\src\main\AndroidManifest.x??ml
Error:The markup in the document preceding the root element must be well-formed.
Run Code Online (Sandbox Code Playgroud)
我试着在这个网站上看,但答案对我不起作用.
<?xml version="1.0" encoding="utf-8"?>
< manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.brandon.MineDodge" >
<application
android:allowBackup="true"
android:icon="@mipmap/redjet"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.brandon.MineDodge.MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name="com.example.brandon.MineDodge.Splash" />
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</application>
</manifest>
Run Code Online (Sandbox Code Playgroud)
San*_*ues 22
如果您使用的是旧版本的build.grade文件,则应删除此代码:
sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = ['src']
res.srcDirs = ['res']
}
}
Run Code Online (Sandbox Code Playgroud)
然后,构建>清理项目
| 归档时间: |
|
| 查看次数: |
49096 次 |
| 最近记录: |