![]() ![]() ![]() ![]() Gravitybox Schedule Primer
Page 21
1998-2004 Gravitybox Software LLC
property. If an applications language is not English or different text needs to be
displayed other than the default, the DisplayName property may be set to the desired
text. This text will be used as the header of Room columns, on the schedule.
Table 1.3
Rooms Collection Definition
Add
This method takes parameters to create a new Room object
and adds it to the Rooms collection. A reference it the created
object is returned.
Clear
This method will clear the collection of all Room objects.
Count
This method will return the number of elements in the
collection.
DisplayName
This is the text that will appear as the room header on the
schedule. The default text is Rooms, but may be set to any
text preferred.
Exists
Given a Room objects name or index, this method will return
true if a Room object exists, at the specified position in the
collection.
Index
This method is very similar to the Exists method only it returns
a number. Given a Room objects name or index, this method
returns its index. Though valid syntax, it is not very useful to
give the index in order to retrieve it. This function was designed
to take the Name property as a parameter.
IsDirty
This property will determine if any modifications have occurred,
since the last time it was set to false. If any property of any
Room object is modified this property is automatically set to
true.
Item
Given a Room objects name or index, this method will return a
reference to the object. If the given parameter does not exist in
the collection, an error is raised. To avoid an error, use the
Exists method in conjunction with this method.
NewIndex
This read-only property is the index of the newest object added
to the collection with the Add method. After the Remove
method is called this property is reset to zero.
Remove
Given a valid index or name, this method will remove the
specified room object.
Rename
This method will rename a Room object. It takes a parameter of
an existing objects index or name and the new name to give
the object. If the new name already belongs to another Room
object, an error is raised.
NOTE: An appointments Room property is not aware of changes in the Rooms
collection. If an appointment has a Room property of 2, referring to the second room in
the Rooms collection and this element is removed, the appointment will still point to the
|