04-22-2015 08:26 AM
Hello,
I have a problem with adding time to string timestamp that is shown on image below.
What I need is to add some time eg. 1 hour, but if that change happens between 23:00 and 00:00 I need to change date to.
Wanted results for example:
14:53, 22.4.2015. --> 15:53, 22.4.2015.
23:33, 22.4.2015. --> 00:33, 23.4.2015.
Please help
Solved! Go to Solution.
04-22-2015 09:11 AM
04-22-2015 09:17 AM
Use the Get Date/Time in Seconds function to get the time, use this form to add and subtract time (to add an hour, simply add 60*60 seconds), and use the Time-Stamp input to the Format Date/Time function when you want a String implementation.
Bob Schor
04-22-2015 09:22 AM
1 - use timestamps instead.
2 - if you are stuck with strings because they are coming from elsewhere, convert back into a timestamp to do the math
04-22-2015 09:39 AM
Here are two ways. One adds a time value from string, the other adds a time value from a double.
04-23-2015 12:56 AM
Hello,
@Dennis_Knutson I must work with strings because they are going elsewhere and they must be strings.
Thank you for help. This was exactly what I needed.
Bye
04-23-2015 02:04 AM