[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Classes' (#rtl)

# TDataModule.OnCreate

Event handler, called when the datamodule is created.

## Declaration

Source position: classesh.inc line 2163

`published property TDataModule.OnCreate : TNotifyEvent read FOnCreate write FOnCreate;`

## Description

The OnCreate event is triggered when the datamodule is created and streamed. The exact moment of triggering is dependent on the value of the OldCreateOrder property.

## See also

TDataModule.Create |  | Create a new instance of a TDataModule.
TDataModule.CreateNew |  |
TDataModule.OldCreateOrder |  | Determines when OnCreate and OnDestroy are triggered.