Note: This page includes content based on the F1 documentation for Centura development. It may be partially converted to support APF development, but should be regarded to be of uncertain actuality. It is provided as is. Eventually, it should be replaced by documentation available from within Visual Studio.
SalNumber DataSourceSave( SalNumber nWhat )
Applications and the framework call the DataSourceSave method to save all changes in a top-level window.
Name | Description |
---|---|
SalNumber nWhat | Standard method parameter. Possible values are Const.METHOD_Inquire, Const.METHOD_Execute, Const.METHOD_GetType. |
When nWhat = Const.METHOD_Inquire: the return value is true if any changes have been made in the data source.
When nWhat = Const.METHOD_Execute: the return value is true if entire save transaction is successful and all changes have been committed.
When nWhat = Const.METHOD_GetType, the return value is Const.CHILDTYPE_SourceMethod.
The DataSourceSave is the start of the save process. It will perform client and server validation of all data sources (in the master-detail chain), start a transaction, save all changes, and commit or rollback the transaction.
Saving of changes is done in the following way:
Each of these nine steps is executed for all data sources in the master-detail chain before the next steps begin. For instance, validation is performed for all data sources before the transaction begins.
DataSourceSave is called automatically by the framework when a data source receives the PM_DataSourceSave message.