Popular Posts

Tuesday, December 27, 2011

Visual Basic 10 new features - Visual studio 2010

There are many cool features in VB 10 ... some of my best ones may include:


 ' multiline Lambda expression
 Dim addUpFunc = Function(x As Integer, y As IntegerAs Double
                            Return x + y
                 End Function

' Collection initaliser
 Dim list As New List(Of StringFrom {"Rahman""Hosha"}
' Multi line continuation without the need for under score _
 Dim sql = "Select name, " &
            "Age, city, country from " &
             "From Individual"


' Auto Properties - without the need for getters and setters
 Public Property Name As String = String.Empty


' Array literals - with type inferring eg without defining the type of the array or number of 
elements
 Dim numbers = {1, 2, 3, 4}
more info:

http://msdn.microsoft.com/en-us/library/ff637436.aspx

No comments:

Post a Comment