I'm making an android app that needs to show a message when it's first started. For example: the user installs my app and runs. In this run, the app displays a message for the app to get a license and the user clicks "ok" to accept the terms and release the app.
From there, the next time it runs the application, this message should not be displayed again.
I tried to make a counter in OnCreate
but it did not. Is there anything I can do?
My logcat
after entering the user code @array
:
02-26 16:42:40.895: D/AndroidRuntime(818): Shutting down VM
02-26 16:42:40.895: W/dalvikvm(818): threadid=1: thread exiting with uncaught exception (group=0x40a71930)
02-26 16:42:40.935: E/AndroidRuntime(818): FATAL EXCEPTION: main
02-26 16:42:40.935: E/AndroidRuntime(818): java.lang.RuntimeException: Unable to resume activity {com.example.testegerador/com.example.testegerador.MainActivity}: android.app.SuperNotCalledException: Activity {com.example.testegerador/com.example.testegerador.MainActivity} did not call through to super.onResume()
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2742)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:2771)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2235)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.access$600(ActivityThread.java:141)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1234)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.os.Handler.dispatchMessage(Handler.java:99)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.os.Looper.loop(Looper.java:137)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.main(ActivityThread.java:5041)
02-26 16:42:40.935: E/AndroidRuntime(818): at java.lang.reflect.Method.invokeNative(Native Method)
02-26 16:42:40.935: E/AndroidRuntime(818): at java.lang.reflect.Method.invoke(Method.java:511)
02-26 16:42:40.935: E/AndroidRuntime(818): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
02-26 16:42:40.935: E/AndroidRuntime(818): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
02-26 16:42:40.935: E/AndroidRuntime(818): at dalvik.system.NativeStart.main(Native Method)
02-26 16:42:40.935: E/AndroidRuntime(818): Caused by: android.app.SuperNotCalledException: Activity {com.example.testegerador/com.example.testegerador.MainActivity} did not call through to super.onResume()
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.Activity.performResume(Activity.java:5184)
02-26 16:42:40.935: E/AndroidRuntime(818): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2732)
02-26 16:42:40.935: E/AndroidRuntime(818): ... 12 more
02-26 16:44:05.165: I/Process(818): Sending signal. PID: 818 SIG: 9