The short answer is no, at least not in the same sense as C#. Here is a snippet on how to initialize a collection in C#.
List<Phone> oPhone = new List<Phone> {
new Phone { PersonId = 1, Number = "111.111.1111" },
new Phone { PersonId = 2, Number = "222.222.2222" }
};
As you can see , in C#, it is possible to initialize a collection in one line of code. To my knowledge, in VB.NET, it requires an additional line of code and the use of a built-in extension method.
Dim arrPhone As Phone() = { _
New Phone With {.PersonId = 1, .Number = "111.111.1111"}, _
New Phone With {.PersonId = 2, .Number = "222.222.2222"} _
}
Dim phoneList As List(Of Phone) = arrPhone.ToList()
Guess the movie
Hey, listen, I want somebody good - and I mean very good - to plant that gun. I don't want my brother coming out of that toilet with just his dick in his hands, alright?