VB.NET 1.1 Tutorial - The New Keyword


The New keyword is used to create objects and invoke constructors, for example;

lblHello = New Label() 

It is also used to invoke the default constructor for value types, for example:

Dim MyArray As Integer()
MyArray = New Integer() {0, 1, 2, 3} 

The New keyword cannot be overloaded.


References

For more information on the New Keyword, visit MSDN at microsoft here.

What Next?

Return to the Tutorial Contents.