You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let formatter = DateFormatter() formatter.locale = Locale(identifier: "en_US_POSIX")
formatter.timeZone = TimeZone(secondsFromGMT: 0) // not sure if this is required - need to test
let maybeDate = formats.reduce(nil as Date?) { result, format in
The text was updated successfully, but these errors were encountered:
See: https://developer.apple.com/library/archive/qa/qa1480/_index.html
My fix: (I'm UK based & parsing Barclays Bank ofx files which use the date format 20191217000000[-5:EST]
let formatter = DateFormatter()
formatter.locale = Locale(identifier: "en_US_POSIX")
formatter.timeZone = TimeZone(secondsFromGMT: 0) // not sure if this is required - need to test
let maybeDate = formats.reduce(nil as Date?) { result, format in
The text was updated successfully, but these errors were encountered: