[Overview][Types][Classes][Procedures and functions][Index] | Reference for unit 'ExtCtrls' (#lcl)

# TUNBPages.Add

Creates a new page instance with the specified name.

## Declaration

Source position: extctrls.pp line 109

`public function TUNBPages.Add(`
`const S: string`
`):Integer; override;`

## Arguments

`S` |  | Name for the page added in the method.

## Function result

Ordinal position where the page object was stored.

## Description

Add is an overridden Integer function used to create a new TPage instance with the name specified in S. The page object is created using the return value from GetNotebookOwner as the owner of the class instance. Add calls the AddObject method to store the page object in the list of pages for the notebook.

The return value contains the ordinal position in the page list where the page object was stored.