From RAD Studio API Documentation
Jump to: navigation, search


property AfterGetRecords: TRemoteEvent read FAfterGetRecords write FAfterGetRecords;


__property Datasnap::Dbclient::TRemoteEvent AfterGetRecords = {read=FAfterGetRecords, write=FAfterGetRecords};


Type Visibility Source Unit Parent
event protected
Datasnap.Provider TCustomProvider


Occurs after the provider creates a data packet to send to the client dataset.

Write an AfterGetRecords event handler to send custom information to a client dataset when providing a data packet. AfterGetRecords is part of the mechanism by which a provider and a client dataset communicate information about data fetching. When the provider is part of a stateless application server, this mechanism allows the provider and the client dataset to communicate persistent state information.

When the client dataset calls the AS_GetRecords method of the IAppServer interface, the following events occur:

1.The provider receives a BeforeGetRecords event, where it can respond to or change custom information that the client dataset sends.

2.If it is a dataset provider, the provider receives an OnGetData event where it can edit the data before creating a data packet, and then generates the data packet.

3.The provider receives an AfterGetRecords event, where it can encode custom information into its OwnerData parameter or respond to information from the BeforeGetRecords event handler.

4.The client dataset receives an AfterGetRecords event, where it can respond to the custom information returned by the provider in its AfterGetRecords event handler.

AfterGetRecords is of type Datasnap.DBClient.TRemoteEvent.

See Also