Issue
I have created an App and works fine on A real device with Gingerbread (I haven't any others devices at the moment). The problem:
If I try to run the same App in the emulator configured to use JellyBean and Google Api when I open an activity that show a google map, Crashes without any error log, simply the screen becomes black and Eclipse open a debug perspective that shows
"Source Not Found"
Thread [<1> main] (Suspended (exception RuntimeException))
<VM does not provide monitor information>
ActivityThread.performLaunchActivity(ActivityThread$ActivityClientRecord, Intent) line: 2059
ActivityThread.handleLaunchActivity(ActivityThread$ActivityClientRecord, Intent) line: 2084
ActivityThread.access$600(ActivityThread, ActivityThread$ActivityClientRecord, Intent) line: 130
ActivityThread$H.handleMessage(Message) line: 1195
ActivityThread$H(Handler).dispatchMessage(Message) line: 99
Looper.loop() line: 137
ActivityThread.main(String[]) line: 4745
Method.invokeNative(Object, Object[], Class, Class[], Class, int, boolean) line: not available [native method]
Method.invoke(Object, Object...) line: 511
ZygoteInit$MethodAndArgsCaller.run() line: 786
ZygoteInit.main(String[]) line: 553
NativeStart.main(String[]) line: not available [native method]
... nothing about the missing source or the line in my class that has caused the error in logcat
Solution
This could happen in these cases:
A) Your activity doesn't extends MapActivity(but if works on real device this is not the case)
B) Your app doesn't import Google Api (but if works on real device this is not the case)
C) The emulator is configured to use Android SDK instead Google API
D) There is some line that refers to null value in the emulator this could happen if you invoke getLastKnownLocation(...)
: because your device has already known any location your app works on the smartphone but not in a new emulator
Do some test and let me know if the problem persists post the code of your Activity.
Answered By - Silverstorm
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.