VISUAL BASIC for APPLICATIONS TEST

Progress

1.

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

2.

What will be the output of the following statement?

txtBox.Text = FormatCurrency(1234.567)

3.

A Combo box is loaded in the From_Initialize event with:

Combo1.AddItem “Red”

Combo1.AddItem “Blue”

Combo1.AddItem “Green”

4.

The _______________ control used to insert image to the form

5.

VBA Code run by

6.

An object is composed of :

7.

32-bit Software/Applications can be installed on:

8.

___________ control is used to provide an identifiable grouping for other controls

9.

Which character in VBA, indicates start of a comment

10.

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

11.

This operator reverses the truth value of an expression; making a true expression false and a false expression true.

12.

Which of the following arithmetic operations has the highest level of precedence?

13.

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

14.

The _______________ statement first executes the statements and then tests the condition after each execution

15.

What property of controls tells the order they receive the focus when the tab key is pressed during run time? it.

16.

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?

17.

What will the value of ThisVar be after the following lines of code execute? 

Dim ThisVar As String 
Dim MyName = "John" 
ThisVar = MyName & "John"


 

18.

__________ are the attributes of an object that control the object's appearance and behavior.

19.

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

20.

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

21.

This control is used for titles/captions

22.

To break up long lines of code, the line continuation character in VBA is

23.

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

24.

What data type can hold any type of data?

25.

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

26.

A single Case statement can contain multiple values

27.

To save a VBA project with an Excel workbook, the workbook must be saved as what type of file?

28.

The Properties window plays an important role in the development of Visual Basic Applications. It is mainly used

29.

___________ indicates whether a particular condition is on or off

30.

Which of the following statements is not true about user-defined functions?

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