I’ve got the next java code:
SimpleDateFormat formatter = new SimpleDateFormat("kk:mm");
Date rangoInicio = formatter.parse(filtroHorariosIda.get(0));
The value for filtroHorariosIda.get(0) is “7” (quotes includes because it’s a string)
The problem is java throws the exception
java.text.ParseException Unparseable date: "7"
I’ve been reading the java docs and I think it’s a perfectly parsing operation. Where’s the problem?
Thanks.
That’s because you’re trying to parse “7” and saying that it should use “kk:mm” format.
Try this instead