Skip to content

TParam.SetData

Set the parameter value from a buffer.

Declaration

Source position: db.pas line 1466

public 
procedure TParam.SetData(Buffer: Pointer);

Description

SetData performs the reverse operation of TParam.GetData: it reads the parameter value from the memory area pointed to by Buffer. The size of the data read is determined by TParam.GetDataSize and the type of data by TParam.DataType : it is the same storage mechanism used by TField, and so can be used to copy the value from a TDataset record buffer.

Errors

Not all field types are supported. If an unsupported field type is encountered, an EDatabaseError exception is raised.

See also

Name Description
TDataset Base class for records-based data-access.
TParam.GetData Get the parameter value from a memory buffer.
TParam.DataType Data type of the parameter.
TParam.GetDataSize Return the size of the data.