this code runs fine on android and emulator from my test it produces: "dateTodayS: Fri Aug 31, dayName: Fri monthName: Aug, dayDate: 31, monthNumber:08",
but on real ios it produces: "dateTodayS: August 31, dayName: Aug monthName: st, dayDate: 1, monthNumber:08", I realise its just parsing different because of the result from parsing the date, but shouldnt it behave identically on all platforms? _("DateStringHolder received "+stringDate); SimpleDateFormat dateTodaySDF = new SimpleDateFormat("yyyy-MM-dd"); Date dateToday = null; //a date object representing the string they passed in try { dateToday = dateTodaySDF.parse(stringDate); String dateTodayS = dateToday.toString(); dayName = dateTodayS.substring(0,3); monthName = dateTodayS.substring(4,7); dayDate = dateTodayS.substring(8,10); monthNumber= stringDate.substring(5,7); //for testing differences on ios and android! Dialog.show("ios debug", "dateTodayS:"+dateTodayS+", dayName:"+dayName+", monthName:"+monthName+", dayDate:"+dayDate+", monthNumber:"+monthNumber, "OK", "Cancel"); } catch(Exception e) { _("**warning** cant parse date! "+e.getMessage()+" ->"+stringDate); e.printStackTrace(); } -- You received this message because you are subscribed to the Google Groups "CodenameOne Discussions" group. To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsubscr...@googlegroups.com. Visit this group at https://groups.google.com/group/codenameone-discussions. To view this discussion on the web visit https://groups.google.com/d/msgid/codenameone-discussions/c2286ffa-b149-49aa-85ea-8fc37a69b775%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.