c# - GetIndexParameters() empty on Dictionary property -


i'm using reflection info class i'm exporting excel. loops through properties values.

i want able handle indexed types lists , dictionarys. however, getindexparameters() method on property returning none. using wrong?

here can see prop.property (which propertyinfo) showing value dictionary<int, decimal>, indexparams has 0 length.

loop logic (slightly modified so, partially pseudocode)

foreach (var prop in exportingpropertiesinorder) {     //detect if needs have indexing applied.     var indexparams = prop.property.getindexparameters();     var isindexed = indexparams.any();     if (!isindexed)     {         //get value property export     }else{         //loop through indeces, each value     } 

the property shown on screenshot dictionary<int, decimal> tiervalues

it not indexer, getindexparameters() method on property returning empty array

dictionary<int, decimal> type has indexed property item


Comments

Popular posts from this blog

Payment information shows nothing in one page checkout page magento -

tcpdump - How to check if server received packet (acknowledged) -