Class Car Public PetName As String Public ID As Integer End Class
Module Program Sub Main() Dim inventory As XElement = _
<Inventory>
<Car ID="1">
<Color>Green</Color>
<Make>BMW</Make>
<PetName>Stan</PetName>
</Car>
</Inventory>
' Call ToString() on our XElement.
Console.WriteLine(inventory)