WinStudio

IsObjectInvalid Method

Applies To

IWSIDOCollection interface

Definition

Returns a Boolean value indicating whether an object in a specified IDO collection is in an error state.

Syntax

object.IsObjectInvalid( integer )

  Part

  Description

object Required. The name of a valid IDO collection object.
integer Required. The index number of an object in the entries for the current IDO collection.

Remarks

A return value of:

If the specified IDO collection might not have focus, use this method. If the specified IDO collection has focus, use the IsCurrentObjectInvalid method.

Example

Sub Main()
    Dim bValue As Boolean
    Dim i As Integer
    Dim curCol As IWSIDOCollection
    curCol = ThisForm.PrimaryIDOCollection()
    For i = 0 To ThisForm.PrimaryIDOCollection.GetNumEntries() - 1
        bValue = curCol.IsObjectInvalid(i)
        If bValue And curCol.IsObjectModified(i) Then
            curCol.SetObjectModified(i, False)
        End If
    Next i
End Sub