en:software:qview:qview_6:qcl_library:vc10calendar

This translation is older than the original page and might be outdated. See what has changed.

VC10Calendar

V = Variables

C = Calculation functions

The VC10Calendar function calculates the day of the week (iin numerical form see the Note) starting from the date expressed as day, month and year starting from 1/1/2000.
The function sets a negative value if you passed a wrong topic. The value determines the type of error.

VC10Calendar (day, month, year, numday)

Parameters:

IN/OUTVARIABLE TYPEEXAMPLE NAMEDIM
IN SYSTEM day L Number of the day (1÷31)
IN SYSTEM month L Number of the month (1÷12)
IN SYSTEM year L Year - 4 digits - (from 2000 onwards)
OUT SYSTEM numday L Day of the week expressed in number:
0 = Sunday
1 = Monday
2 = Tuesday
3 = Wednesday
4 = Thursday
5 = Friday
6 = Saturday

If there was any data entry error would be reported on the numday variable with negative values. In particular:
-1 = error in entering the day
-2 = error in entering the month
-3 = error in entering the year
-4 = error in entering the day February month

Example

In the example, If the day of the week of June 19, 2002 is Wednesday, it activates 'ofUscita' output.

day = 19
month = 6
year = 2002
VC10Calendar (day, month, year, numday)
IF (numday EQ 3)
	SETOUT ofUscita
ENDIF

Note

  • The function execute a WAIT a time every 180 milliseconds
  • Last modified: 2019/08/29 17:01