Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

datevec (MathScript Function) (Windows, Not in Base Package)

LabVIEW 8.5 Help
August 2007

NI Part Number:
371361D-01

»View Product Info

Member of the time class.

Syntax

v = datevec(s, pivotyear)

v = datevec(s)

v = datevec(n)

[y, m, d, h, mi, se] = datevec(s, pivotyear)

[y, m, d, h, mi, se] = datevec(s)

[y, m, d, h, mi, se] = datevec(n)

Description

Converts a time from a string or a double-precision, floating-point number to a vector.

Examples

Inputs

Name Description
s Specifies a time. s is a string.
pivotyear Provides information about the century if you use the form yy in s. If pivotyear is less than 0, LabVIEW considers s to be a time in the current century. The default is -1.
n Specifies a time. n is a double-precision, floating-point number.

Outputs

Name Description
v Returns the time. v is a vector.
y Returns the year.
m Returns the month.
d Returns the day.
h Returns the hour.
mi Returns the minute.
se Returns the second.

Examples

s = '05-Apr-06';
v = datevec(s)

Related Topics

date
datenum
datestr


Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit