I have recently installed Eclipse IDE for Java Developers (Version: 3.6.1) with the Android SDK Platform 2.1update1 - on Windows 7.
I can add, edit and run code for
I have solved my problem by changing app theme in manifest file.. like..
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" >
I solved this problem by deleting my custom device configuration.
You may have to close and reopen your layout file.
What if you want to use a custom device configuration? From someone on the android team:
Make sure that if you have custom devices, you edit them and add every available config item into the right listview.
I found copying one of the default configurations and changing values as needed, did the trick.
Android Issue Tracking > Issue 17522: ADT 11 problem "No XML content. Please add a root view or layout to your document." > Comment 10
I'm on WinXP Pro SP3, Eclipse Indigo (3.7.0), building against Android 2.2/Level 8 (Which I installed after encountering the 'missing theme error' when building against Android 2.1-update1). I don't know if changing platforms helped.
Changing the target platform in the "graphical layout" of a layout.xml file from android 2.2 to android 2.1-update1 reintroduced problems from some of my layouts. So maybe you need a complete device configuration and to build against android 2.2 (or, at least, set android 2.2 as the platform for each particular xml file and build the rest of the application against an earlier platform, if need be).
I had the same issue. I solved it by adding a theme attribute to the Android manifest file. I needed a single theme for all the Activities hence I added the attribute at Application level as follows.
`<application android:icon="@drawable/icon"
android:label="@string/app_name"
android:theme="@android:style/Theme.Black">`
Then I closed my Activity UI xml file and re-opened it..and the problem was fixed.
Have you added the tag into the manifest? Maybe the designer is looking there for a theme and it is not there.
Hope it helps!