PropertyInfo.GetValue method and ArrayList

M

Marius Horak

The weekend is coming so you will have plenty of time to find the right
answer. I did search the Net but could not find anything useful.

I have no problems with GetValue(obj, null) for a simple property but
cannot figure out how to use this method if the property is a
collection (eg. ArrayList) with unknown number of items.
I made two or tree attempts but none was working.
I was getting that the array item count is zero and when I tried to get
items withing the array size it was always null(s) instead of item(s).

Thanks

MH
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top