Monday, January 23, 2012

[android-developers] getApplicationContext() returns null?

Has anybody seen this happen?

I have the following line in my code:

XmlResourceParser xml =
getAppplicationContext().getResources().getXml(R.xml.database_tables);

Somebody reported a NPE on that line, so it can either be
getAppplicationContext() or getResources() returning a null. The
same line works for countless other users.

Anybody has any clues?

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate