| Visual Basic 2008 » Chapter 9 » Chapter 9.3 |
| Chapter 9 : Using Constants, Variables and Arrays |
Working with VariablesVariables are similar to constants in that when you reference a variable's name in code, Visual Basic substitutes the variable's value in place of the variable name during code execution. This doesn't happen at compile time, though, as it does with constants. Instead, it happens at runtime the moment the variable is referenced. This is because variables, unlike constants, can have their values changed at any time.
Chapter 9.3.1: Declaring Variables The act of defining a variable is called declaring, which is most commonly accomplished using the keyword Dim. Read more...
Chapter 9.3.2: Passing Values to a Variable The syntax of assigning a literal value to a variable depends on the variable's data type. Read more...
Chapter 9.3.3: Using Variables in Expressions Variables can be used anywhere an expression is expected, operate on expressions. Read more...
Chapter 9.3.4: Explicit Variable Declaration In the past, Visual Basic's default behavior enabled you to create variables on-the-fly. Read more...
Strict typing is the process by which Visual Basic enforces data typing. Read more... |