From RAD Studio API Documentation
Jump to: navigation, search


function CreateParam(FldType: TFieldType; const ParamName: string;  ParamType: TParamType): TParam;


TParam* __fastcall CreateParam(TFieldType FldType, const System::UnicodeString ParamName, TParamType ParamType);


Type Visibility Source Unit Parent
function public
Data.DB TParams


Creates a new field parameter object and inserts it into the Items list.

Call CreateParam to instantiate a new TParam object and add it to the Items managed by this TParams object. Specify the field type of the new parameter as the value of FldType, specify the name of the parameter as the value of ParamName, and specify the type of parameter as the value of ParamType.

Note: Parameters for datasets that represent queries are only created by specifying parameters in the SQL statement. The TParam objects in such as dataset's Params property are created automatically when parameter tokens are added to the SQL statement.

See Also

Code Examples