Note that there are some explanatory texts on larger screens.

plurals
  1. POMultiple Activities in Android
    primarykey
    data
    text
    <p>I am creating multiple activities in Android. When I run the app, it can't connect to other activities so just wondering. These are my code, I have 3 xml files and 3 java files. </p> <p>This is logcat log file.</p> <p>log.txt</p> <pre><code>05-03 01:57:10.335: E/PhonePolicy(23020): Could not preload class for phone policy: com.android.internal.policy.impl.PhoneWindow$ContextMenuCallback 05-03 01:57:12.665: W/dalvikvm(23020): threadid=1: thread exiting with uncaught exception (group=0x409db1f8) 05-03 01:57:12.705: E/AndroidRuntime(23020): FATAL EXCEPTION: main 05-03 01:57:12.705: E/AndroidRuntime(23020): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.jumoun.itemp/com.jumoun.itemp.Temperature}: java.lang.NullPointerException 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1880) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread.access$600(ActivityThread.java:123) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.os.Handler.dispatchMessage(Handler.java:99) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.os.Looper.loop(Looper.java:137) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread.main(ActivityThread.java:4427) 05-03 01:57:12.705: E/AndroidRuntime(23020): at java.lang.reflect.Method.invokeNative(Native Method) 05-03 01:57:12.705: E/AndroidRuntime(23020): at java.lang.reflect.Method.invoke(Method.java:511) 05-03 01:57:12.705: E/AndroidRuntime(23020): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795) 05-03 01:57:12.705: E/AndroidRuntime(23020): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:562) 05-03 01:57:12.705: E/AndroidRuntime(23020): at dalvik.system.NativeStart.main(Native Method) 05-03 01:57:12.705: E/AndroidRuntime(23020): Caused by: java.lang.NullPointerException 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.Activity.findViewById(Activity.java:1794) 05-03 01:57:12.705: E/AndroidRuntime(23020): at com.jumoun.itemp.Temperature.&lt;init&gt;(Temperature.java:14) 05-03 01:57:12.705: E/AndroidRuntime(23020): at java.lang.Class.newInstanceImpl(Native Method) 05-03 01:57:12.705: E/AndroidRuntime(23020): at java.lang.Class.newInstance(Class.java:1319) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.Instrumentation.newActivity(Instrumentation.java:1023) 05-03 01:57:12.705: E/AndroidRuntime(23020): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1871) 05-03 01:57:12.705: E/AndroidRuntime(23020): ... 11 more 05-03 01:57:14.115: I/Process(23020): Sending signal. PID: 23020 SIG: 9 </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload