Oh yes of course, here it is: Error: null java.lang.ArrayIndexOutOfBoundsException at com.android.internal.widget.NumberPicker.updateView (NumberPicker.java:238) at com.android.internal.widget.NumberPicker.setCurrent (NumberPicker.java:180) at android.widget.DatePicker.updateSpinners(DatePicker.java:299) at android.widget.DatePicker.init(DatePicker.java:289) at nl.magnatron.streetwars.EditProfile $GetProfileTask.onPostExecute(EditProfile.java:142) at nl.magnatron.streetwars.EditProfile $GetProfileTask.onPostExecute(EditProfile.java:1) at android.os.AsyncTask.finish(AsyncTask.java:416) at android.os.AsyncTask.access$300(AsyncTask.java:127) at android.os.AsyncTask$InternalHandler.handleMessage (AsyncTask.java:428) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:123) at android.app.ActivityThread.main(ActivityThread.java:3948) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:521) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:782) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540) at dalvik.system.NativeStart.main(Native Method)
I thought my String[] was wrong, but via the debugger i can see 0,1 and 2 are populated just like they should. On 6 okt, 15:54, "Mark Murphy" <mmur...@commonsware.com> wrote: > > I'm having a weird problem. When I try to update my DatePicker it > > crashes, but I dont understand why. Via the debugger I could see the > > date[] function is filled the way it should be. > > > Do you guys see the problem? > > > String[] date = dateofbirthNode.getStringValue().split("/"); // > > "12/31/1969" > > DatePicker dateofbirthView = (DatePicker)findViewById > > (R.id.editprofile_dateofbirth_picker); > > dateofbirthView.init(Integer.parseInt(date[2]), Integer.parseInt(date > > [1]), Integer.parseInt(date[0]), null); > > What did the Java stack trace tell you? You can view that via adb logcat, > DDMS, or the DDMS perspective in Eclipse. > > -- > Mark Murphy (a Commons Guy)http://commonsware.com > Android App Developer Books:http://commonsware.com/books.html --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---