troubles creating a List of doubles from a list of objects
- by Michel
Hi,
i have a list with objects. The object has a property 'Sales' which is a string.
Now i want to create a list of doubles with the values of all objects' 'Sales' properties.
I tried this:
var tmp = from n in e.Result select new{ Convert.ToDouble ( n.Sales) };
but this gives me this error:
Error 106 Invalid anonymous type member declarator. Anonymous type members must be declared with a member assignment, simple name or member access.