I am having the collection which is dynamic
type. I have stored the double values in the collection. For some records, I am not store the data to it. Now I need to get this type as nullable
double to perform some operations. Is there any way to get the data property type as nullable
while using Expando
object ?
ObservableCollection<dynamic> dynamicItems = new ObservableCollection<dynamic>();
for (int j = 1; j <= 4; j++)
{
dynamic data = new ExpandoObject();
if (j == 2)
{
// not store the value when j is 2.
}
else
{
data.colValues = 12.2 * j;
}
dynamicItems.Add(data);
}