When working with time elements in smart forms, you can configure the time format for display in fields and lists. This allows times to show up in military time. (HH:mm), which is desired in my project.
However, it seems the picker tool to allow users to enter time values does not format military time? Only provides AM/PM radio buttons?
I looking for a way to allow time picker tool to accept military time input.
Thanks for confirmation on this limitation.
This can be done, but it is kind of a pain. The first thing you want to do is go in to your web.config files for your SmartForms. Those can be found at the following:
In those web.config files (open them in notepad) you need to locate the following:
<!-- SmO Execution Settings -->
<add key="SmartObject.ExecutionCulture" value="en-US"/>
the "en-US" need to be changed to "hh:mm:ss". I am fairly certain that is what it needs to be changed too, but that is ISO format so verifying should be easy.
Additionally, to avoid issues with time discrepancies you should also ensure your local computer is on the same 24h clock.
Do an IISRESET and restart the K2 Host Server and you should be set.
Thanks for the suggestion, Austin,
Feels like this wil lonly change the display within the data entry form.. and not formally adjust the dialog to accept military time. Will this somehow disable the AM/PM portion of data entry? I would very much need those removed in this solution, since expecting 24 hour time.. but then also show option to select AM/PM is not a good option.
You also mention avoiding issues with time discrepancies and ensuring my local computer is on the same 24h clock.
Are you suggesting that I just display 24 hour time on my machine keep data entry clear? Or are you mentioning some other technical angle?
This smart form is expected to be deployed and view my numerous users, all over the US.. and obviously across various time zones. I'm currently battling an issue with date entry taken from one timezone and then displayed in a browser running in another timezone. Looking for best practice with K2 smartform when dealing with this. Wondering if your comment about my local machine impacts my solution elsewhere. (I'm just developing this form and will never use final business solution)
On my end it seems to work. I'm using BP 4.6.8/SF 1.0.7. I was wrong about what to set "<add key="SmartObject.ExecutionCulture" value=" to though. You need to pick a language and country that uses a 24 hour clock. So France or some such.