โ† All Excel VBA Flashcard Decks

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
  1. 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.

  2. 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.

  3. Which VBA data type stores True or False values?

    Answer: Boolean

    The Boolean data type in VBA holds only True or False values.

  4. 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.

  5. In VBA, which operator is used for string concatenation?

    Answer: &

    The ampersand (&) operator is the standard VBA operator for joining strings together.

  6. 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.