First app and so really new at android (played around about a year ago but nothing came of it), decent at programming. Wanting to make sure app renders on a phone, no functi
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.Object.toString()' on a null object reference
at android.widget.ArrayAdapter.createViewFromResource(ArrayAdapter.java:394)
at android.widget.ArrayAdapter.getView(ArrayAdapter.java:362)
at android.widget.AbsSpinner.onMeasure(AbsSpinner.java:193)
at android.widget.Spinner.onMeasure(Spinner.java:482)
This tells you that the error was measuring the Spinner. More exactly, one of the strings that should be displayed inside it is null.
The most likely cause is a problem with the @array/arraySplitr resource. Is it a valid string-array resource as defined in the documentation?
This:
- 2
...
should be instead:
- 2
...
The array element is for Typed Arrays. String arrays must use string-array.