ComponentOne True DBInput Pro 8.0
Add Method (DaysCollection)

Adds a Day object in the DaysCollection and returns a reference to the created object. The Days collection is 1 based. A new Day can easily be added by using the property page at design time, and using the Add method at runtime.

Syntax

object.Add (Key, [Name], Date, [Date2], [Type])

Arguments

key is a required, unique string that identifies the Day. Use key to retrieve a specific Day. This is equivalent to setting the Key property of the new Day object after the object has been added to the Days collection.

name is an optional variant: the name or description of the holiday. This is equivalent to setting the Name property in the new Day object.

date is a required variant (Date): the date to set as holiday or forced workday. This is equivalent to setting the Date property in the new Day object.

date2 is an optional variant(Date): the end date when specifying a range of dates. This is equivalent to setting the Date2 property in the new Day object.

type is an optional value indicating the type of the day: holiday, or forced workday, etc This is equivalent to setting the Type property in the new Day object. The possible valid settings for the type parameter are as follows:

0

Holiday (Default)

1

Force Holiday

2

Force Workday

Return Value

Object (Day)

 

 


Copyright (c) GrapeCity, inc. All rights reserved.

Product Support Forum  |  Documentation Feedback