java.lang.RuntimeException: Unable to start activity ComponentInfo{com.milos.sportisa/com.milos.sportisa.SplashActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.TextView.setTypeface(android.graphics.Typeface)' on a null object reference

Stack Overflow | ajzaklija | 7 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Trying to set custom font on TextView - nullpointer

    Stack Overflow | 7 months ago | ajzaklija
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.milos.sportisa/com.milos.sportisa.SplashActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.TextView.setTypeface(android.graphics.Typeface)' on a null object reference

    Root Cause Analysis

    1. java.lang.NullPointerException

      Attempt to invoke virtual method 'void android.widget.TextView.setTypeface(android.graphics.Typeface)' on a null object reference

      at com.milos.sportisa.SplashActivity.onCreate()
    2. com.milos.sportisa
      SplashActivity.onCreate
      1. com.milos.sportisa.SplashActivity.onCreate(SplashActivity.java:29)
      1 frame
    3. Android Platform
      ActivityThread.performLaunchActivity
      1. android.app.Activity.performCreate(Activity.java:5933)
      2. android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
      3. android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2251)
      3 frames