VISUAL BASIC for APPLICATIONS TEST

Progress

1.

Given the following section of code, if a programmer called the GetAge() subroutine, what value would the message box display? 

Private Sub GetAge()

Dim UserAge As String

UserAge = 10

UserAge = InputBox("Enter your age", "Get Age")

Call ShowAge

End Sub

Private Sub ShowAge()

Dim UserAge As Integer

UserAge = 0

MsgBox (UserAge)

End Sub

2.

_______________ is the function to compare 2 strings.

3.

To force all variables is a VBA project to be declared, which must be stated in a module?

4.

Which event, runs macros automatically in excel VBA while opening Workbook

5.

When the form is first referenced in any manner by program,the triggered event is….

6.

You have declared 4 variables

 Which of these variable declarations is not a valid VBA statement?

7.

Which character in VBA, indicates start of a comment

8.

___________ function is used to return a copy of a string without leading spaces.

9.

What will be the output of the following code?

Sub LoopExample()

Dim StartNumber As Integer

Dim EndNumber As Integer

Dim Answer As Integer

Answer = 5

EndNumber = 5

For StartNumber = 1 To EndNumber

Answer = Answer + EndNumber

Next StartNumber

MsgBox Answer

      End Sub

10.

VBA Code run by

11.

An array that maintains multiple sets of information referenced by more than one index is called ________________

12.

Which part of VBA window, refers to area where code is written.

13.

A single Case statement can contain multiple values

14.

Suppose the variable myName is declared in a Dim statement in two different Sub procedures. Which statement is true?

15.

What value is stored in a variable of type single if we try to assign the variable to the value 634?

16.

What do you need to select to set the developer mode?

17.

A ______________ returns a value to the part of the program that called it.

18.

Study the screenshot below. What is the appropriate action to take when a workbook displays this message (Security Warning Macros have been disabled)?

19.

Which of the following is default in VBA for data passing?

20.

The _______________ control used to insert image to the form

21.

To close a form named Form1, you can use:

22.

Why Macro is used

23.

Which of the following statement is not a looping statement in VBA?

24.

Which property for a textbox allows the textbox to accept more than 1 line of data entry?

25.

___________ indicates whether a particular condition is on or off

26.

To load graphics on a control at runtime, we have to use the function….

27.

The value returned by InputBox is a string

28.

Suppose you are designing an application for admissions to a college or university, and you need to decide how to provide the user with a selection of racial backgrounds. Which control would be most appropriate?

29.

Do…Loop... Until code block is always executed once.

30.

An object is composed of :

Assessment complete! Thank you for you time.
We are redirecting you to the result page, Please click on 'SUBMIT'