Online Exam Quiz

questionQuestion  1 to 30

How do you add a border to a cell in VBA?

  • Range("A1").Borders.LineStyle = xlContinuous
  • Range("A1").Border = xlContinuous
  • Range("A1").Borders.Style = xlContinuous
  • Range("A1").Borders.Add
Mark for review

How do you access the value of a cell using VBA?

  • cell.value
  • cell.text
  • cell.data
  • cell.contents
Mark for review

How do you declare a constant in VBA?

  • constant
  • declare constant
  • const
  • define constant
Mark for review

How do you make a cell value bold using VBA?

  • Range("A1").Font.Bold = True
  • Range("A1").Bold = True
  • Range("A1").Font.Bold = "True"
  • Range("A1").Font.Bold = "1"
Mark for review

Which statement is used to loop through a range of cells in VBA?

  • for loop
  • while loop
  • do-while loop
  • for each loop
Mark for review

How can you add a new worksheet to an Excel workbook using VBA?

  • Worksheets.Add
  • Sheets.New
  • AddSheet
  • Workbook.Sheets.Add
Mark for review

What does the keyword "Option Explicit" do in VBA?

  • Enables case sensitivity
  • Forces declaration of all variables
  • Disables debugging
  • Hides errors
Mark for review

Which event occurs when a workbook is opened in Excel?

  • Workbook_Open
  • Workbook_Start
  • Workbook_Load
  • Workbook_Begin
Mark for review

What does the term "Object-Oriented Programming" mean in the context of VBA?

  • Programming with objects and classes
  • Programming with loops and conditions
  • Programming with arrays and variables
  • Programming with macros and functions
Mark for review

What keyword is used to exit a loop in VBA?

  • Break
  • Exit
  • End
  • Stop
Mark for review

Which method is used to insert a row in a worksheet in VBA?

  • InsertRow()
  • AddRow()
  • Insert()
  • Rows.Insert()
Mark for review

What is the purpose of DoEvents in VBA?

  • Allows other operations to run
  • Ends a loop
  • Pauses execution
  • Ends the macro
Mark for review

What does the Cells(1,1).Value statement refer to?

  • Cell A1
  • Cell B1
  • Cell A2
  • Cell B2
Mark for review

Which object is used to manipulate the Excel workbook?

  • Workbook
  • Workbooks
  • Sheet
  • Worksheet
Mark for review

What is the purpose of the Range object in VBA?

  • Access Excel formulas
  • Manipulate cell formatting
  • Work with ranges of cells
  • Create new worksheets
Mark for review

How do you insert a new module in the VBA editor?

  • Insert > Module
  • File > New Module
  • Home > New Module
  • Developer > New Module
Mark for review

How can you add a comment to a cell using VBA?

  • Range("A1").AddComment "CommentText"
  • Range("A1").Comment = "CommentText"
  • Range("A1").Comment.Text = "CommentText"
  • Range("A1").AddComment "CommentText"
Mark for review

What is the purpose of the End statement in VBA?

  • To end a loop or procedure
  • To end a function
  • To end a workbook
  • To end a variable
Mark for review

How do you clear the contents of a cell in VBA?

  • ClearCell()
  • DeleteCell()
  • ClearContents()
  • RemoveCell()
Mark for review

Which method is used to save a workbook in VBA?

  • Save()
  • SaveAs()
  • SaveWorkbook()
  • Export()
Mark for review

How do you concatenate strings in VBA?

  • concat()
  • join()
  • &
  • concatString()
Mark for review

What does the Application.Volatile statement do?

  • Makes a function volatile
  • Makes a cell's value volatile
  • Makes a macro volatile
  • Makes the workbook volatile
Mark for review

How do you check if a file exists in VBA?

  • FileExists()
  • CheckFile()
  • FileExist()
  • DoesFileExist()
Mark for review

Which property is used to access the cells in a worksheet using VBA?

  • Cells
  • Range
  • Rows
  • Columns
Mark for review

Which function is used to display a message box in VBA?

  • MsgBox()
  • Alert()
  • ShowMessage()
  • DisplayAlert()
Mark for review

How do you execute a VBA macro from a button click in Excel?

  • RunMacro()
  • ExecuteMacro()
  • CallMacro()
  • Assign macro to button
Mark for review

How do you declare a global variable in VBA?

  • Global
  • DeclareGlobal
  • Public
  • GlobalVar
Mark for review

Which statement is used to declare a variable in VBA?

  • var
  • dim
  • declare
  • variable
Mark for review

How can you handle errors in VBA?

  • Using On Error Resume Next
  • Using On Error GoTo
  • Using ErrorHandler
  • Using Try-Catch
Mark for review

What is the purpose of the "With" statement in VBA?

  • Specify conditional statements
  • Group multiple statements
  • Access properties of an object
  • Define variables
Mark for review

blinkerOnline

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • Answered
  • Not Answered
  • Marked for Review