FireDAC.Phys.MongoDBDataSet.TFDMongoQuery.BeforePost

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property BeforePost: TDataSetNotifyEvent read FBeforePost write FBeforePost;

C++

__property BeforePost;

Properties

Type Visibility Source Unit Parent
event published
FireDAC.Phys.MongoDBDataSet.pas
FireDAC.Phys.MongoDBDataSet.hpp
FireDAC.Phys.MongoDBDataSet TFDMongoQuery

Description

Occurs before an application posts changes for the active record to the database or change log.

FireDAC.Phys.MongoDBDataSet.TFDMongoQuery.BeforePost inherits from Data.DB.TDataSet.BeforePost. All content below this line refers to Data.DB.TDataSet.BeforePost.

Occurs before an application posts changes for the active record to the database or change log.

Write a BeforePost event handler to take specific action before an application posts dataset changes. BeforePost is triggered when an application calls the Post method. Post checks to make sure all required fields are present, then calls BeforePost before posting the record.

An application might use BeforePost to perform validity checks on data changes before committing them. If it encountered a validity problem, it could call Abort to cancel the Post operation (Delphi) or throw an exception (C++).

BeforePost is an event handler of type Data.DB.TDataSetNotifyEvent.

See Also

Code Examples