The library to parse the time string in Processbook is PITimeServer. That is why you are seeing a difference. However you are right that AF SDK is unable to parse "1 6:". You can see the parse results using AFTime.TryParse. Regarding whether this is a bug or a design decision, I will leave that for our devs to answer.
1 of 1 people found this helpful
This limitation is documented in the AF SDK reference: AFTime Constructor (String).
Some formats with missing hours, minutes, and/or seconds that were supported by PI Time are not supported. For example "hh:mm" is supported, but "hh::ss", ":mm:ss", and "::s" are some formats that are not supported. The format must be supported by the DateTime.TryParse method.
I encourage you to check out the documentation for detailed information, in case you have questions about whether other time formats are supported.
Hey John, I trust you've moved on after 3 years, but for anyone else reading this, the correct syntax would be new AFTime("1+6h"). This would produce a time at 6 AM local time of the first of the current month. To get 6 AM local time for the first of the current year, the correct time string would be "1/1+6h".