Reputation: 4043
Suppose that my function gets a two dimensional array as input and its dimensions are unknown. How can I figure them out using reflection?
Upvotes: 2
Views: 850
Reputation: 887453
You don't need reflection for this.
You can call the GetLength method of the Array class and pass the dimension index.
GetLength
Array
Upvotes: 6