SetObjectForceUpdate method (WinStudio scripts)

Applies To

IWSIDOCollection interface

Definition

Forces a change from a SQL INSERT operation to a SQL UPDATE operation in the middle-tier processing of the object in a specified IDO collection.

Syntax

object.SetObjectForceUpdate( integer, Boolean )

  Part   Description
object Required. A reference to a valid IDO collection object.
integer Required. An integer indicating the index number of an object in the entries for the current collection.
Boolean Required. Determines whether the operation is changed:
  • TRUE: INSERT is changed to UPDATE.
  • FALSE: INSERT is not changed to UPDATE.

Remarks

It is your responsibility to determine whether it is appropriate to change from an INSERT to an UPDATE operation. Neither WinStudio nor the middle tier performs error checking to determine whether using this method is appropriate.

Example

Sub Main()
   Dim intIndex As Integer
   If ThisForm.PrimaryIDOCollection.IsCurrentObjectPropertyModified("StringTableName") Then
      intIndex = ThisForm.PrimaryIDOCollection.GetCurrentObjectIndex()
      ThisForm.PrimaryIDOCollection.SetObjectForceUpdate(intIndex, True)
   End If
End Sub