Using VB.NET (3.5), i have an ArrayList of Employees. I'm trying to build an XML representation (to feed another system) and one of the fields is a simple incrementing ID, starting at 1. The code I currently have is:
Dim Emps = <Employees>
<%= From ee As Employee In Employees _
Select <Employee>
<EmployeeID>1</EmployeeID>
<DateOfBirth><%= ee.DOB %></DateOfBirth>
<ZipCode>
<Zip><%= ee.ZIP %></Zip>
</ZipCode>
</Employee> %>
</Employees>
How can I increment the EmployeeID field, I'm not sure how using this simple LINQ query.
Thanks.