PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
  • Range selection
  • Modifying a period in a Calendar, Organizer or Scheduler control
  • Special cases
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
The Property DateFin allows you to know and modify the end date of the selected period:
  • in a Calendar control,
  • Windows in an Organizer control.
  • Windows in a Scheduler control.
Example
// Retrieve the selected period (Calendar control)
NbDays is int
NbDays = DateDifference(CAL_Calendar1.StartDate, ...
CAL_Calendar1.EndDate) + 1
Info("Selected period: from " + ...
DateToString(CAL_Calendar1.StartDate) + ...
" to " + DateToString(CAL_Calendar1.EndDate) + ...
" which means " + NbDays + " days")
Syntax

Finding out the end date of the period Hide the details

<End date> = <Control used>.EndDate
<End date>: Character string or Date variable
  • End date of the period selected in the control.
    • In a Calendar control, this date is in "YYYYMMDD" format.
    • Windows In an Organizer control or Planning, this date is in "YYYYMMDDHHmmSSCCC" format.
  • Date of the selected day if a day is selected,
  • Empty string ("") if no day is selected.
<Control used>: Control name
Name of control used:
  • Calendar control,
  • Windows Organizer control.
  • Windows Scheduler control.

Modifying the end date of the period Hide the details

<Control used>.EndDate = <New date>
<Control used>: Control name
Name of control used:
  • Calendar control,
  • Windows Organizer control.
  • Windows Scheduler control.
<New date>: Character string or Date variable
End date of the period to select in the control.
  • In a Calendar control, this date is in "YYYYMMDD" format.
  • Windows In an Organizer control or Planning, this date is in "YYYYMMDDHHmmSSCCC" format.
Remarks

Range selection

To select a period :
  • in a Calendar control, " Range selection" must be selected in the "Details" tab.
  • Windows in an Organizer control, the option "Allow time range selection" must be selected in the "Details" tab.
  • Windows in a Scheduler control, the option "Allow time range selection" must be selected in the "Details" tab.

Modifying a period in a Calendar, Organizer or Scheduler control

To change the start date of a selected period, it is necessary to specify the start date (Property StartDate) and the end date of the period (Property EndDate).. Indeed, the modification of the start date:
  • automatically deselects the end date.
  • waits for the end date to be selected (by programming or via a click on a control date).
0: the period is automatically modified.

Special cases

  • The start date of a period is returned and modified by StartDate.
  • StartDate returns the start date of the period according to the chronological order. Therefore, if the end date was selected before the start date, StartDate will return the last date that was selected.
Minimum version required
  • Version 14
This page is also available for…
Comments
Click [Add] to post a comment