Excel VBA Fundamentals & Syntax Flashcards
6 cards from real Excel VBA practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 6 Excel VBA Fundamentals & Syntax flashcards as text
Which keyword is used to declare a variable in VBA?
Answer: Dim
In VBA, the Dim keyword is used to declare variables before they are used.
What is the correct way to start a VBA subroutine?
Answer: Sub MySub()
A VBA subroutine begins with the Sub keyword followed by the subroutine name and parentheses.
Which VBA data type stores True or False values?
Answer: Boolean
The Boolean data type in VBA holds only True or False values.
What does the Option Explicit statement do in VBA?
Answer: Requires all variables to be declared before use
Option Explicit forces the programmer to explicitly declare all variables, reducing bugs caused by typos.
In VBA, which operator is used for string concatenation?
Answer: &
The ampersand (&) operator is the standard VBA operator for joining strings together.
Which VBA loop construct checks its condition BEFORE executing the loop body?
Answer: Do Until...Loop
Do Until...Loop evaluates the condition before each iteration and stops when the condition is True.