The managed language team made big leap
New Productivity - Improving Syntax❘1009
After a long time, the Managed Language Team made a big leap. Visual Basic 2010 allows omitting
“Apple”, “Peach”, “Orange”,
“Banana”, “Lemon”, “Pear”,
Where fruit.StartsWith(“P”) And fruit.Length < 20
Order By fruit
➤ After an open parenthesis ( ( ) or before a closing parenthesis ( ) ).
➤ After an open curly brace ( { ) or before a closing curly brace ( } ).
➤ After the Is and IsNot operators.
➤ After a member qualifi er character ( . ) and before the member name. However, you must
With keyword.
➤ After a less - than sign ( < ) or before a greater - than sign ( > ) when you specify an attribute.
Skip While ).
➤ After the In keyword in a For Each statement.
This list of options to leave the underscore means that you can actually omit underscores from every location where it seems natural. If you would like to see samples and more details about statements and line continuation, navigate to http://msdn.microsoft.com/en-us/library/865x40k4(VS.100).aspx .
Getting rid of the mandatory line continuation means that now you can break and indent your Visual Basic code easier than ever before.
Public Class OrderItem
‘ ...End Class