views:

543

answers:

2
[2010-04-16 23:31:34 - MobileDataKeeper] Error in an XML file: aborting build.
[2010-04-16 23:31:57 - MobileDataKeeper] Error in an XML file: aborting build.
[2010-04-16 23:32:28 - MobileDataKeeper] Error in an XML file: aborting build.
[2010-04-16 23:34:56 - MobileDataKeeper] Error in an XML file: aborting build.
[2010-04-16 23:35:14 - MobileDataKeeper] res/layout/main.out.xml:0: error: Resource entry main is already defined.
[2010-04-16 23:35:14 - MobileDataKeeper] res/layout/main.out.out.xml:0: Originally defined here.
[2010-04-16 23:35:14 - MobileDataKeeper] res/layout/main.xml:0: error: Resource entry main is already defined.
[2010-04-16 23:35:14 - MobileDataKeeper] res/layout/main.out.out.xml:0: Originally defined here.
[2010-04-16 23:35:14 - MobileDataKeeper] /media/Mis Documentos/Dropbox/Eclipse/MobileDataKeeper/res/layout/main.out.out.xml:1: error: Error parsing XML: no element found
[2010-04-16 23:35:14 - MobileDataKeeper] /media/Mis Documentos/Dropbox/Eclipse/MobileDataKeeper/res/layout/main.out.xml:1: error: Error parsing XML: no element found
[2010-04-16 23:35:49 - MobileDataKeeper] Error in an XML file: aborting build.

Main.xml.out.* are empty. The MobileDataKeeper.java is default and the Mainx.xml out is:

<?xml version="1.0" encoding="utf-8"?>

<RelativeLayout
    android:id="@+id/RelativeLayout01"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    xmlns:android="http://schemas.android.com/apk/res/android" />

Every time i change something in the Main.xml get this problem. It's very frustrating and I don't know what the heck is going on. A trained eye is requiered!

Thanks!

+3  A: 

Delete all main.xml.out files in your project. Then, do NOT attempt to run the project with an XML file as the active tab in the editor in Eclipse -- switch to a Java file. It is the attempt to run the project with an XML file as the active tab that creates those .out files and messes up the system.

There's probably a more sophisticated workaround, but I am not an Eclipse user, so I do not know what it is.

CommonsWare
Yes, i figured this out for myself. Thanks!
Gabriel A. Zorrilla
Most useful answer. What an awful bug in Eclipse - I thought I was going stupid or blind looking for the bad xml that didn't exist!
NickT
+1  A: 

Delete the main.out.xml, if you still can't run, then follow this:
Eclipse -> Project -> Clean... -> Choose your project -> OK

Silence of 2012