hey guys I am using the following code to save an XML file:
Dim xml As New XElement("Roles", From r In _Roles _
Select New XElement("Role", New XAttribute("name", r.roleName), _
New XElement("user", r.assignedUsers)))
xml.Save(fileName)
This works to create the following:
<?xml version="1.0" encoding="utf-8"?>
<Roles>
<Role name="Admin">
<user>user1user2</user>
</Role>
<Role name="User">
<user>user1user2user3</user>
</Role>
<Role name="Guest">
<user>user4user5</user>
</Role>
<Role name="Power User">
<user>user3</user>
</Role>
</Roles>
as you can see all the users a grouped in the one element. I know that I should more than likely use another Select statement to generate the User elements but I am not sure how to do this camn you please advise?
Cheers
Thanks and Thanks again!!
Tuppers