When eclipse imports an existing android project, it encounters an error in the AndroidManifest.xml file (red cross)

If you import an existing Android project, the steps are as follows:

1. Copy the project to the previously created workspace folder;

2.import--> android /Existing Android Code Into Workspace-->next-->select the project file under the workspace folder-->check Copy projects into workspace-->finish;

3. Later, you will find that there is a red exclamation mark in front of the project name just imported in eclipse, and there is a red cross in the Android Manifest.xml of the project; the following information is reported in the Console:

[2013-05-02 17:01:28 - MixView] Project has no target set. Edit the project properties to set one.
[2013-05-02 17:01:28 - com.android.ide.eclipse.adt. internal.project.AndroidManifestHelper] Parser exception forE:\AndroidWorkspace\MixView\AndroidManifest.xml: File ended prematurely.
[2013-05-02 17:01:28 - MixView] Project has no target set. Edit the project properties to set one.
[2013-05-02 17:01:29 - MixView] Parser exception for /MixView/AndroidManifest. xml: file ended prematurely.

And the Android Manifest.xml file is empty. The Java file under src is also empty, and the xml file under layout is also empty.

The reason for the above problem is that the project file is copied to the workspace folder before importing. If it is directly imported in another folder, the above problem will not occur.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326120211&siteId=291194637