ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Format Date/Time String Function

I found some odd behaviour in LabView 2010 Format Date/Time String Function. It does return wrong 07 week number, when it should today (20.2.2013) retun week 08. Time format string is "%W%y". Has somebody found solution how to go around the problem?

 

 

Download All
0 Kudos
Message 1 of 4
(3,427 Views)

It is doing what it says it will do, please read the help: http://zone.ni.com/reference/en-XX/help/371361G-01/glang/codes_for_time_format_str/

 

Excerpt from the help:

<%W> week number of the year (00–53), with the first Monday as the first day of week one; 00 represents the first week

CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
0 Kudos
Message 2 of 4
(3,419 Views)

help says : 

<%W> week number of the year (00–53), with the first Monday as the first day of week one; 00 represents the first week

 

EDIT :

Damn a second too late Smiley Sad


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

Message 3 of 4
(3,416 Views)

Be advised that the %W and %w date formatters in LabVIEW are not ISO-8601 compliant.

 

https://decibel.ni.com/content/docs/DOC-7199

 

There is a link in this example to a thread containing info about calculating an ISO-80601 week number.

 

 

Message 4 of 4
(3,392 Views)