Tutorial by Examples

Comparison operators compare two values and return to you a boolean (True or False) as the result. Equality The equal sign = is used both for equality comparison and assignment. If leftValue = rightValue Then ... Inequality The left angle bracket nest to the right angle bracket <> p...
There is a single assignment operator in VB. The equal sign = is used both for equality comparison and assignment. Dim value = 5 Notes Watch out for assignment vs. equality comparison. Dim result = leftValue = rightValue In this example you can see the equal sign being used as both a c...
If you have the following variables Dim leftValue As Integer = 5 Dim rightValue As Integer = 2 Dim value As Integer = 0 Addition Performed by the plus sign +. value = leftValue + rightValue 'Output the following: '7 Subtraction Performed by the minus sign -. value = leftValue - rig...
These are the bitwise operators in VB.NET : And, Or, Xor, Not Example of And bitwise operation Dim a as Integer a = 3 And 5 The value of a will be 1. The result is obtained after comparing 3 and 5 in binary for. 3 in binary form is 011 and 5 in binary form is 101. The And operator places 1 if ...
String concatenation is when you combine two or more strings into a single string variable. String concatenation is performed with the & symbol. Dim one As String = "Hello " Dim two As String = "there" Dim result As String = one & two Non-string values will be conv...

Page 1 of 1