I can't understand the reason of NumberFormatException in this code:
SimpleDateFormat format = (SimpleDateFormat) SimpleDateFormat.getDateInstance();
Below is my LogCat output:
10-30 18:04:05.600: W/System.err(23899): java.lang.NumberFormatException: Invalid int: ""
10-30 18:04:05.600: W/System.err(23899): at java.lang.Integer.invalidInt(Integer.java:138)
10-30 18:04:05.600: W/System.err(23899): at java.lang.Integer.parseInt(Integer.java:359)
10-30 18:04:05.600: W/System.err(23899): at java.lang.Integer.parseInt(Integer.java:332)
10-30 18:04:05.600: W/System.err(23899): at java.util.Calendar.getHwFirstDayOfWeek(Calendar.java:807)
10-30 18:04:05.600: W/System.err(23899): at java.util.Calendar.<init>(Calendar.java:745)
10-30 18:04:05.600: W/System.err(23899): at java.util.GregorianCalendar.<init>(GregorianCalendar.java:338)
10-30 18:04:05.600: W/System.err(23899): at java.util.GregorianCalendar.<init>(GregorianCalendar.java:314)
10-30 18:04:05.608: W/System.err(23899): at java.text.SimpleDateFormat.<init>(SimpleDateFormat.java:378)
10-30 18:04:05.608: W/System.err(23899): at java.text.SimpleDateFormat.<init>(SimpleDateFormat.java:368)
10-30 18:04:05.608: W/System.err(23899): at java.text.DateFormat.getDateInstance(DateFormat.java:462)
10-30 18:04:05.608: W/System.err(23899): at java.text.DateFormat.getDateInstance(DateFormat.java:443)
10-30 18:04:05.608: W/System.err(23899): at java.text.DateFormat.getDateInstance(DateFormat.java:426)
10-30 18:04:05.608: W/System.err(23899): at com.mycompany.mypackage.InboxFragment$15.setViewValue(InboxFragment.java:396)
Edit:
The same exception for DateFormat format = DateFormat.getDateInstance();
DateFormat format = DateFormat.getDateInstance();
– Champ