Table of Contents

TatCustomScripter.AddDataModule Method

Registers the data module instance ADataModule to be accessible from all scripts, exposing its owned components as properties.

Remarks

AddDataModule registers the data module instance specified by ADataModule to be accessible from all scripts. The data module will be accessible by its name. AddDataModule is similar to AddComponent, but the difference is that all components owned by the data module are made available as properties of the data module class. This way if you have an object MyDataModule you can access their components directly using for example MyDataModule.Table1.

Syntax

Unit: atScript

procedure TatCustomScripter.AddDataModule(ADataModule: TDataModule; ADataModuleClassName: string);

Parameters

<-> Parameter Type Description
ADataModule TDataModule
ADataModuleClassName string

See also