WinStudio

UpdateStatesPostSave Method

Applies To

IWSIDOCollection interface

Definition

Performs operations that WinStudio normally performs after a save operation (see "Remarks" below).

Syntax

object.UpdateStatesPostSave( )

  Part

  Description

object

Required. A reference to a valid IDO collection object.

Remarks

After a save operation, WinStudio normally performs the following tasks:

This method performs the three operations that WinStudio normally performs after a Save but does not save objects in a collection. This method is designed to be used with the SaveDeferStateUpdate method, which saves objects in a collection but does not perform the three tasks.

In some cases, you might need to execute actions after a successful Save operation has occurred, but before the three tasks are performed. If your actions fail, you can then rollback the effects of the save. The SaveDeferStateUpdate method, used in conjunction with this method, allows you to do this.

This method does not save objects and must be used with caution because data changes appear to have been committed to the database.

Example

Sub Main()
   Dim bSuccess As Boolean
   Dim ReturnValue As String
   bSuccess = ThisForm.CurrentIDOCollection.SaveDeferStateUpdate()
   If (bSuccess) Then
   End If
   If (bSuccess) Then
      ThisForm.CurrentIDOCollection.UpdateStatesPostSave()
   Else
   End If
   ReturnValue = "-1"
End Sub

Related Topics

SaveCurrentDeferStateUpdate Method

UpdateCurrentStatePostSave Method