Creator Help

toStartOfWeek

This topic describes the syntax and usage of the tostartofweek function in Zoho Creator .

Description

Returns the first date of the week, for the specified date. For example, if date value is July, 04 2013, which is a Thursday, the function returns June,30,2013 which is a Sunday, the starting day of the week.

Syntax

toStartOfWeek(<date>)

The toStartOfWeek function syntax has the following arguments.

date - A date in date/date-time format that represents the date. 

Note: This function is supported only in free-flow scripting mode of Script Builder. 

Return Value

A date (datetime).

Example

a. In this example, the " toStartOfWeek" function returns the starting date of the week for the transaction date.

  toStartOfWeek(TransactionDate);

Top