This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Create .NET Arrays of Generic Type

This example creates a .NET array of List<Int32> generic type.

genType = NET.GenericClass('System.Collections.Generic.List',...
arr = NET.createArray(genType, 5)
arr = 

  List<System*Int32>[] with properties:

            Length: 5 
        LongLength: 5 
              Rank: 1 
          SyncRoot: [1x1 System.Collections.Generic.List<System*Int32>[]] 
        IsReadOnly: 0 
       IsFixedSize: 1 
    IsSynchronized: 0 
Was this topic helpful?