Hi. I have this array defined:
public static string[,,] collections = new string[2, 201, 5];
..and I want to be sure it's empty when I call my readconfig function. I see there is Array.Clear, which you pass Array array, int index and int length. Does that mean I have to do:
Array.Clear(collections, 0, 2);
Array.Clear(collections, 1, 201);
Array.Clear(collections, 2, 5);
or is there a different / proper way to do it? Thanks!
Loading
VulpesPosted Aug 21, 2011, 7:38 PM
Array.Clear(collections, 0, 2 * 201 * 5);
Console.WriteLine(collections[1, 200, 4] == null); // true
KenPosted Aug 22, 2011, 10:28 PM