Documentation Center

  • Trial Software
  • Product Updates

Accessing Items in .NET Collections

Use the Item property of the System.Collections.Generic List class to get or set an element at a specified index. Since Item is a property that takes arguments, MATLAB® maps it to a pair of methods to get and set the value. For example, the syntax to use Item to get a value is:

Return TypeNameArguments
System.String RetValItem(System.Collections.Generic.
List<System*String> this,
int32 scalar index)

The syntax to use Item to set a value is:

Return TypeNameArguments
noneItem(System.Collections.Generic.
List<System*String> this,
int32 scalar index,
System.String value)

Was this topic helpful?