- VB.Net Basic Tutorial
- VB.Net - Home
- VB.Net - Overview
- VB.Net - Environment Setup
- VB.Net - Program Structure
- VB.Net - Basic Syntax
- VB.Net - Data Types
- VB.Net - Variables
- VB.Net - Constants
- VB.Net - Modifiers
- VB.Net - Statements
- VB.Net - Directives
- VB.Net - Operators
- VB.Net - Decision Making
- VB.Net - Loops
- VB.Net - Strings
- VB.Net - Date & Time
- VB.Net - Arrays
- VB.Net - Collections
- VB.Net - Functions
- VB.Net - Subs
- VB.Net - Classes & Objects
- VB.Net - Exception Handling
- VB.Net - File Handling
- VB.Net - Basic Controls
- VB.Net - Dialog Boxes
- VB.Net - Advanced Forms
- VB.Net - Event Handling
- VB.Net Advanced Tutorial
- VB.Net - Regular Expressions
- VB.Net - Database Access
- VB.Net - Excel Sheet
- VB.Net - Send Email
- VB.Net - XML Processing
- VB.Net - Web Programming
- VB.Net Useful Resources
- VB.Net - Quick Guide
- VB.Net - Useful Resources
- VB.Net - Discussion
VB.Net Mock Test
This section presents you various set of Mock Tests related to VB.Net. You can download these sample mock tests at your local machine and solve offline at your convenience. Every mock test is supplied with a mock test key to let you verify the final score and grade yourself.
VB.Net Mock Test III
Q 1 - Which of the following accesss modifier specifies that Visual Basic should marshal all strings to Unicode values regardless of the name of the external procedure being declared?
Answer : D
Explanation
Unicode − Specifies that Visual Basic should marshal all strings to Unicode values regardless of the name of the external procedure being declared.
Q 2 - Which of the following accesss modifier indicates that a conversion operator (CType) converts a class or structure to a type that can hold all possible values of the original class or structure?
Answer : A
Explanation
Widening − Indicates that a conversion operator (CType) converts a class or structure to a type that can hold all possible values of the original class or structure.
Q 3 - Which of the following accesss modifier specifies that one or more declared member variables refer to an instance of a class that can raise events?
Answer : B
Explanation
WithEvents − Specifies that one or more declared member variables refer to an instance of a class that can raise events.
Q 4 - Which of the following accesss modifier specifies that a property can be written but not read?
Answer : C
Explanation
WriteOnly − Specifies that a property can be written but not read.
Q 5 - Which of the following statement declares and allocates storage space for one or more variables?
Answer : A
Explanation
Dim − Declares and allocates storage space for one or more variables.
Q 6 - Which of the following statement declares and defines one or more constants?
Answer : B
Explanation
Const − Declares and defines one or more constants.
Q 7 - Which of the following statement declares an enumeration and defines the values of its members?
Answer : C
Explanation
Enum − Declares an enumeration and defines the values of its members.
Q 8 - Which of the following statement declares the name of a class and introduces the definition of the variables, properties, events, and procedures that the class comprises?
Answer : D
Explanation
Class − Declares the name of a class and introduces the definition of the variables, properties, events, and procedures that the class comprises.
Q 9 - Which of the following statement declares the name of a structure and introduces the definition of the variables, properties, events, and procedures that the structure comprises?
Answer : A
Explanation
Structure − Declares the name of a structure and introduces the definition of the variables, properties, events, and procedures that the structure comprises.
Q 10 - Which of the following statement declares the name of a module and introduces the definition of the variables, properties, events, and procedures that the module comprises?
Answer : B
Explanation
Module − Declares the name of a module and introduces the definition of the variables, properties, events, and procedures that the module comprises.
Q 11 - Which of the following statement declares the name of an interface and introduces the definitions of the members that the interface comprises?
Answer : C
Explanation
Interface − Declares the name of an interface and introduces the definitions of the members that the interface comprises.
Q 12 - Which of the following statement declares the name, parameters, and code that define a Function procedure?
Answer : D
Explanation
Function − Declares the name, parameters, and code that define a Function procedure.
Q 13 - Which of the following statement declares the name, parameters, and code that define a Sub procedure?
Answer : A
Explanation
Sub − Declares the name, parameters, and code that define a Sub procedure.
Q 14 - Which of the following statement declares a reference to a procedure implemented in an external file?
Answer : B
Explanation
Declare − Declares a reference to a procedure implemented in an external file.
Q 15 - Which of the following statement declares the operator symbol, operands, and code that define an operator procedure on a class or structure?
Answer : C
Explanation
Operator − Declares the operator symbol, operands, and code that define an operator procedure on a class or structure.
Q 16 - Which of the following statement declares the name of a property, and the property procedures used to store and retrieve the value of the property?
Answer : D
Explanation
Property − Declares the name of a property, and the property procedures used to store and retrieve the value of the property.
Q 17 - Which of the following statement declares a user-defined event?
Answer : A
Explanation
Event − Declares a user-defined event.
Q 18 - Which of the following statement is used to declare a delegate?
Answer : B
Explanation
Delegate − Used to declare a delegate.
Q 19 - Which of the following directive defines conditional compiler constants?
Answer : A
Explanation
#Const − This directive defines conditional compiler constants.
Q 20 - Which of the following directive is used for indicating a mapping between specific lines of source code and text external to the source?
Answer : B
Explanation
#ExternalSource − This directive is used for indicating a mapping between specific lines of source code and text external to the source. It is used only by the compiler and the debugger has no effect on code compilation. This directive allows including external code from an external code file into a source code file.
Q 21 - Which of the following directive conditionally compiles selected blocks of Visual Basic code?
Answer : C
Explanation
#If...Then...#Else − This directive conditionally compiles selected blocks of Visual Basic code.
Q 22 - Which of the following directive helps in collapsing and hiding sections of code in Visual Basic files?
Answer : D
Explanation
#Region − This directive helps in collapsing and hiding sections of code in Visual Basic files.
Q 23 - Which of the following operator returns the address of a procedure?
Answer : A
Explanation
AddressOf − Returns the address of a procedure.
Q 24 - Which of the following operator is applied to an operand in an asynchronous method or lambda expression to suspend execution of the method until the awaited task completes?
Answer : B
Explanation
Await − It is applied to an operand in an asynchronous method or lambda expression to suspend execution of the method until the awaited task completes.
Q 25 - Which of the following operator returns a Type object for the specified type?
Answer : C
Explanation
GetType − It returns a Type object for the specified type. The Type object provides information about the type such as its properties, methods, and events.
Answer Sheet
Question Number | Answer Key |
---|---|
1 | D |
2 | A |
3 | B |
4 | C |
5 | A |
6 | B |
7 | C |
8 | D |
9 | A |
10 | B |
11 | C |
12 | D |
13 | A |
14 | B |
15 | C |
16 | D |
17 | A |
18 | B |
19 | A |
20 | B |
21 | C |
22 | D |
23 | A |
24 | B |
25 | C |