java.lang.RuntimeException: Unable to start activity ComponentInfo{pdfshare.hemanthreddy.com.pdfshare/pdfshare.hemanthreddy.com.pdfshare.activities.HomeScreen}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference

Stack Overflow | hemanth5636 | 5 months ago
  1. 0

    ViewPager obj is null even though it initilized correctly and also present in the defined layout xml

    Stack Overflow | 5 months ago | hemanth5636
    java.lang.RuntimeException: Unable to start activity ComponentInfo{pdfshare.hemanthreddy.com.pdfshare/pdfshare.hemanthreddy.com.pdfshare.activities.HomeScreen}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference
  2. 0

    Java coming up with NullExceptionErrors. Have no idea how to fix this

    Stack Overflow | 1 year ago | bob9123
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.FitnessTracker/com.example.FitnessTracker.ExerciseTracker}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference
  3. 0

    How to open an Image from on Itemclick listener

    Stack Overflow | 7 months ago | Neelay Srivastava
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.union.project/com.union.project.Swipeview.Main4Activity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    error when moving from one activity to another activity which is a tabhost

    Stack Overflow | 1 year ago | C.Karrthik Reddy
    java.lang.RuntimeException: Unable to start activiComponentInfo{ks.developers.festoforcollege/ks.developers.festoforcollege.Register}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference
  6. 0

    moving from Fragment to Activity which extends FragmentActivity

    Stack Overflow | 8 months ago | Kr Rakesh
    java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference

    1 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      Attempt to invoke virtual method 'void android.support.v4.view.ViewPager.setAdapter(android.support.v4.view.PagerAdapter)' on a null object reference

      at pdfshare.hemanthreddy.com.pdfshare.activities.HomeScreen.onCreate()
    2. pdfshare.hemanthreddy.com
      HomeScreen.onCreate
      1. pdfshare.hemanthreddy.com.pdfshare.activities.HomeScreen.onCreate(HomeScreen.java:39)
      1 frame
    3. Android Platform
      ActivityThread.main
      1. android.app.Activity.performCreate(Activity.java:6259)
      2. android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1130)
      3. android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2379)
      4. android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2490)
      5. android.app.ActivityThread.access$900(ActivityThread.java:154)
      6. android.app.ActivityThread$H.handleMessage(ActivityThread.java:1354)
      7. android.os.Handler.dispatchMessage(Handler.java:102)
      8. android.os.Looper.loop(Looper.java:148)
      9. android.app.ActivityThread.main(ActivityThread.java:5443)
      9 frames
    4. Java RT
      Method.invoke
      1. java.lang.reflect.Method.invoke(Native Method)
      1 frame
    5. Android
      ZygoteInit.main
      1. com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:728)
      2. com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
      2 frames