Existen algunas formas de hacerlo, acá les dejo un par.
Primera forma:
//list es del tipo IList ArrayList arr = new ArrayList(list); Item[] items = (Item[])arr.ToArray(typeof(Item)); |
Otra forma:
Item[] items = new Item[list.Count]; list.CopyTo(items, 0); |