UserTab Collection Methods

In this section, we discuss the UserTab collection methods. The methods are discussed in alphabetical order.

Syntax

DeleteItem(UserTabName)

Description

The DeleteItem method deletes the UserTab object identified by UserTabName from the UserTab Collection.

This method is not executed automatically. It is executed only when the parent object is saved.

Parameters

Field or Control

Definition

UserTabName

Specify the name of a UserTab existing in the UserTab collection.

Returns

A Boolean value: True if the UserTab was deleted, False otherwise.

Example

If Not &MyColl.DeleteItem("Test_UserTab") Then
   /* can't delete test data. Do error processing */
End-if;

Syntax

First()

Description

The First method returns the first UserTab object in the UserTab collection.

Parameters

None.

Returns

A UserTab object.

Example

&MyUserTab = &MyCollection.First();

Syntax

InsertItem(UserTabName)

Description

The InsertItem method inserts the UserTab object identified by UserTabName into the UserTab Collection.

This method is not executed automatically. It is executed only when the parent object is saved.

The new user tab must be unique within the portal.

Parameters

Field or Control

Definition

UserTabName

Specify the name of a new UserTab. This parameter takes a string value. If you specify a name that already exists in the collection, you get an error.

Returns

A reference to the new UserTab object if the method executed successfully, NULL otherwise.

Syntax

ItemByName(Name)

Description

The ItemByName method returns the UserTab object with the name Name.

Parameters

Field or Control

Definition

Name

Specify the name of an existing UserTab within the UserTab collection. If you specify an invalid name, the object is NULL.

Returns

A UserTab object if successful, NULL otherwise.

Example

&MyUserTab = &MyColl.ItemByName("PORTAL_ADMIN");

Syntax

Next()

Description

The Next method returns the next UserTab object in the UserTab collection. You can use this method only after you have used the First method: otherwise the system doesn’t know where to start.

Parameters

None.

Returns

A UserTab object.

Example

&MyUserTab = &MyCollection.Next();