Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9239483
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T07:59:49+00:00 2026-06-18T07:59:49+00:00

I have published on google play my app. Google is telling me that my

  • 0

I have published on google play my app.
Google is telling me that my app, when was being used by users, crashed 2 times.
I tested my app a lot of times, but i never get that error, and i don’t know how to simulate that error.

java.lang.RuntimeException: Unable to resume activity {com.mdp.slotmachine/com.mdp.slotmachine.CoverActivity}: java.lang.NullPointerException
at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2444)
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:2472)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1986)
at android.app.ActivityThread.access$600(ActivityThread.java:123)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4429)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:562)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.NullPointerException
at android.app.ContextImpl.startService(ContextImpl.java:1088)
at android.content.ContextWrapper.startService(ContextWrapper.java:359)
at com.mdp.slotmachine.CoverActivity.onResume(Unknown Source)
at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1154)
at android.app.Activity.performResume(Activity.java:4539)
at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2434)
... 12 more

The error seems to be in CoverActivity class, inside onResume method. As you can see i don’t do anything in onResume method.

  @Override
  protected void onResume() {
  super.onPause();

  //check if i'm publishing the app on samsung store
        if(MainActivity.samsung){   

          // here i check if my app was properly downloaded from samsung store by using Zirconia.
         // BUT I NEVER GET HERE; BECAUSE THE PREVIUOS VARIABLE (MainActivity.samsung) IS ALWAYS FALSE.
            if(!MainActivity.licensaSamsung){
                    finish();
            }
        }
  }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T07:59:50+00:00Added an answer on June 18, 2026 at 7:59 am

    As per our discussion related to your question, your approach of keeping a final static boolean samsung; in your start Activity is fatal and wrong. This does not work on Android.

    Although there are reasons when you shouldn’t use static variables, I think that’s fine for such purposes as startup analysis of environment aspects.

    The right way to do this on Android is to derive an Application class, perform the analysis there and store it in variables there. Typical design considerations apply, but here’s a basic scheme which may work for you.

    public final class MyApplication extends Application {
        public static boolean isSamsung;
        @Override
        // Application.onCreate() is called on the main thread before your first Activity
        public void onCreate() {
            isSamsung = myFancyComputation();
        }
     }
    

    An Instance of MyApplication is guaranteed to survive as long as you App does not get killed or is terminated. Please note that this may occur erlier or much later than you think; please try to fully understand the Application and Activity lifecycles before you try to rely on them.

    With this static singleton approach, it’s super easy to access Application.isSamsung; however, you could also make it non-static and access it via the Activity’s means to find its Application context.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I have uploaded and published an app in Google Play. It's free, but
I have an app published on google play. I want a url that redirects
I have published an app on Google Play 15 days ago, I made some
I have published my app on google play which uses database. Now what I
I have already published android app on Google Play. It is desired to distribute
I have an android app on Google Play published. When I developed it, I
I have built and published my app on Google Play and everything works fine.
I have developed Mobile Application which is published on Google play. Now client requires
I've been working on an Android App that has already been published to Google
I have an app on google play. I updated the app to 1.0.1, and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.