Crash report: NoSuchFieldError

by Markus » Thu, 21 Oct 2010 15:41:58 GMT


Sponsored Links
 Hi all,

Yesterday I noticed this awkward crash report on the Android Market
Home:

java.lang.ExceptionInInitializerError
at java.lang.Class.newInstanceImpl(Native Method)
at java.lang.Class.newInstance(Class.java:1429)
at android.app.Instrumentation.newApplication(Instrumentation.java:
957)
at android.app.Instrumentation.newApplication(Instrumentation.java:
942)
at android.app.ActivityThread
$PackageInfo.makeApplication(ActivityThread.java:644)
at
android.app.ActivityThread.handleBindApplication(ActivityThread.java:
4232)
at android.app.ActivityThread.access$3000(ActivityThread.java:125)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:
2071)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:123)
at android.app.ActivityThread.main(ActivityThread.java:4627)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:868)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.NoSuchFieldError:
at com.xxx.yyy.Application.<clinit>(Application.java:30)
... 16 more

The device was a Nexus One and apparently this happened twice (but
only to one user).

Any idea what might be the cause of this?

Markus

--



Crash report: NoSuchFieldError

by TreKing » Thu, 21 Oct 2010 22:53:18 GMT


 




First Google hit:
 http://download.oracle.com/javase/1.4.2/docs/api/java/lang/ExceptionInInitializerError.html 

"...thrown to indicate that an exception occurred during evaluation of a
static initializer or the initializer for a static variable."

So look at how your statics are being initialize. Or, if it's only happening
to this one person, ignore it. That's what I do :-P

-------------------------------------------------------------------------------------------------
TreKing < http://sites.google.com/site/rezmobileapps/treking> ; - Chicago
transit tracking app for Android-powered devices

--


Sponsored Links


Other Threads

1. Programatically query ContentProvider

Hello everyone,

is there a possibility to programmatically query a ContentProvider?
I've successfully managed to get every currently on the device
installed ContentProvider via the PackageManager. This gives me every
Content Provider by it's Base-URI in the form of e.g.
com.google.android.notepad.NotePadProvider.
What I want now is to programmatically access this ContentProvider.
But since I don't know the provided tables (in the case of  a DB based
provider) and the exposed fields, I can't query the provider.
What I would need is to programmatically access the exact CONTENT_URI
and the fields of the ContentProvider. But since this is not strictly
specified and every ContentProvider can do it differently (e.g.
com.google.provider.NotePad) I don't see a chance to programmatically
query a ContentProvider discovered via the PackageManager.
The only idea that comes to my mind is to do it via reflection, but
e.g. the constant name CONTENT_URI is only a suggestion by Android and
can't be taken for granted as the exact URI to a provider table.

So my question is, does anyone have an idea on how I could
programmatically get all the data from a ContentProvider without
knowing it's tables/fields beforehand?

Thx in advance,

Chris
--~--~---------~--~----~------------~-------~--~----~

2. Screen orientation switch and data

Hi

I am testing my application on screen orientation switch. The
application loads data from the internet or the device and displays
this data. The interface is working great on the switch do I really
have to reload the data on every switch ? Shouldn't the switch only
affect the interface?
What am I doing wrong?
--~--~---------~--~----~------------~-------~--~----~

3. what does this mean ?

4. AlertDialog that looks like ProgressDialog?

5. Query on upcoming API features

6. Totally Novice to Mobile apps developement

7. Help Installing