List to List by C# 2.0

List<string> data=new List<string>(new string[] { "1","2","3" } ); 
List<decimal> temp = data.ConvertAll<decimal>(delegate(string x) {
                return Convert.ToDecimal(x);
            });

 

你可能感兴趣的:(List to List by C# 2.0)