tags:

views:

1981

answers:

3

I'm new to Android & Eclipse. I've downloaded Eclipse and the Android ADT and created an ultra-simple "Hello World" app (has only auto-generated .java and .xml files).

Eclipse CRASHES (closes after a very brief pause) when I do the following:

  1. In Package Explorer, select AppName/res/layout/main.xml
  2. Press , or double-click, or 'Open With' then 'Android Layout Editor'

(The app runs OK in the Android emulator)

My configuration is:

Android Development Tools 0.9.5.v200911191123-20404 com.android.ide.eclipse.adt.feature.group Eclipse IDE for Java Developers 1.2.2.20100216-1730 epp.package.java

Windows XP

Can someone tell me what I'm doing wrong or what's wrong with my configuration? Any suggestions on what to check? For any non-trivial app development I need to be able to use the Layout Editor.

More ... I can select main.xml and Right-Click and 'Open With' any of: XML Editor, XML Schema Editor, Text Editor -- with no problem. The problem is limited to Android Layout Editor.

THANKS!

A: 

DONT do anything in eclipse while it says "building project" at the bottom right it does this when you load eclipse, and when you run, or add new files.

If you still have the problem, then I cant help you

Nathan
+1  A: 

I found the problem.

I discovered the .log files (under \Android SDK\eclipse-java-galileo ...\eclipse ) These files are apparently created by Eclipse when a fatal exception occurs. Upon examining the latest file I saw

An unexpected error has been detected by HotSpot Virtual Machine:

#

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x6d2521e1, pid=9156, tid=13952

#

Java VM: Java HotSpot(TM) Client VM (1.5.0_02-b09 mixed mode)

Problematic frame:

C [fontmanager.dll+0x121e1]

and when I looked further, found the folder where fontmanager.dll resides.

Deducing that 'fontmanager.dll' was part of the Java runtime, I saw that I'd been using jre1.5.0_02, and, upon checking the Sun site, discovered that it's an outdated file. So I downloaded (from Sun site) and installed the latest version of the Java runtime.

That fixed it! The Android Layout Editor runs without problems.

THANKS to Nathan for his efforts. As it turned out, his suggestion didn't solve this particular problem, but the info he provided will no doubt be useful.

+1  A: 

I think I have the same problem. When I try to open main.xml with the XML Editor Eclipse freezes. Opening with the Text Editor is fine.

What may I need to update? How do I check if I have an outdated version?

Moberg