Not All Required Indexes have been Defined on Writing the <PropertyName> Property

Description

One or more required indexes have been omitted on specifying the value of a property.

Troubleshooting Tips

Specify values of all required property indexes.

Example

Class TestClass: Object
    s: Array Of String;
    
    Public Constructor Create(Length: Integer);
    Begin
        s := New String[Length]
    End Constructor Create;
    
    Public Property Item(i: Integer): String
        Get
        Begin
            Return s[i];
        End Get
        Set
        Begin
            s[i] := Value;
        End Set
    End Property Item;

End Class TestClass;

Sub UserProc;
Var
    Obj: TestClass;
Begin
    Obj := New TestClass.Create(4);
    Obj.Item := 1;
End Sub UserProc;

When the specified code is compiled, the string Obj.Item := 1; displays the following error: Not all required indexes have been defined on writing the Item property. To resolve the error, specify the value of the required index "i".

See also:

Compiler Messages