How do I use reflection to determine the nested type (element type) of an array?

后端 未结 1 2006
春和景丽
春和景丽 2020-12-11 00:26

I have an instance of System.Type, for which \"IsArray\" returns true.

How can I determine the \"nested type\" of the array type?

i.e.

Type          


        
相关标签:
1条回答
  • 2020-12-11 00:55
    t.GetElementType() 
    

    Reference.

    0 讨论(0)
提交回复
热议问题