I have no idea what you mean by "
standard C# LINQ functions"...
If you would like to use
Non-linq solution, you can loop through the collection of customers by using
for
or
foreach
statement:
List<XElement> nodes = new List<XElement>();
foreach(Customer c in customers)
{
var node = new XElement(...);
nodes.Add(node);
}
If you want to use
Linq - lambda expression, try this:
List<XElement> nodes = customers
.Select(x=> new XElement(...))
.ToList();