In a random way, during repetitive operations, this error occurs:
java.text.ParseException: Unparseable date: "2020: 09: 20 12:50:50"
On this date and other dates, but randomly, in the sense that sometimes there are no errors on the same dates
I use this code:
java.text.ParseException: Unparseable date: "2020: 09: 20 12:50:50"
On this date and other dates, but randomly, in the sense that sometimes there are no errors on the same dates
I use this code:
B4X:
Sub GetExifDateTime (Fpath As String, Fname As String) As Long
Dim temp As String
Dim ExifDate As Long
Dim exif As ExifData
exif.Initialize(Fpath, Fname)
temp = exif.getAttribute(exif.TAG_DATETIME)
DateTime.DateFormat = "yyyy:MM:dd HH:mm:ss"
ExifDate = DateTime.DateParse(temp)
Return ExifDate
End Sub
'In starter Service:
Sub Service_Create
Dim jo As JavaObject
jo.InitializeStatic("java.util.Locale").RunMethod("setDefault", Array(jo.GetField("US")))
End Sub