I want to calculate the day of the year out of a given date. NOT out of the current timestamp which is given by the vi "seconds to date/time" in combination with "day/time to seconds". I do not find the way to change the content of a timestamp like "bundle by Name" of a Cluster.
Sounds simple, but i don't want to go the way to calculate the day manually concerning leap years.
Thanks in advance,
Solved! Go to Solution.
Format date/time string with %j as the format code.
There is a function called "Seconds to Date/Time". It outputs a cluster that has an element for day of the year. Feed whatever timestamp you want into that function. Only if you don't wire up a timestamp does it give you the current timestamp.
If your date format is always the same, you can use Scan From String to convert the string into individual numeric values and then build the cluster into a date/time record and convert that to a timestamp.
Actually the Scan from String will automatically output the timestamp for you, if you have the proper format code.
Ok, now I found it. The challenge for me was to find the format string and the related vi.
Thank you very much !!