VB.Net Online Quiz


Following quiz provides Multiple Choice Questions (MCQs) related to VB.Net. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : D

Explanation

All of the above options are correct.

Q 2 - Which of the following accesss modifier specifies that Visual Basic should marshal all strings to American National Standards Institute (ANSI) values regardless of the name of the external procedure being declared in VB.NET?

A - Ansi

B - Assembly

C - Async

D - Auto

Answer : A

Explanation

Ansi − Specifies that Visual Basic should marshal all strings to American National Standards Institute (ANSI) values regardless of the name of the external procedure being declared.

Q 3 - Which of the following accesss modifier is used in generic interfaces and delegates?

A - In

B - Iterator

C - Key

D - Module

Answer : A

Explanation

In − It is used in generic interfaces and delegates.

Q 4 - Which of the following accesss modifier specifies that a class can be used only as a base class and that you cannot create an object directly from it?

A - MustInherit

B - MustOverride

C - Narrowing

D - NotInheritable

Answer : A

Explanation

MustInherit − Specifies that a class can be used only as a base class and that you cannot create an object directly from it.

Q 5 - Which of the following accesss modifier specifies that a declared programming element redeclares and hides an identically named element, or set of overloaded elements, in a base class?

A - Shadows

B - Shared

C - Static

D - Unicode

Answer : A

Explanation

Shadows − Specifies that a declared programming element redeclares and hides an identically named element, or set of overloaded elements, in a base class.

Q 6 - Which of the following statement declares and defines one or more constants?

A - Dim

B - Const

C - Enum

D - Class

Answer : B

Explanation

Const − Declares and defines one or more constants.

Q 7 - Which of the following statement is used to declare a delegate?

A - Event

B - Delegate

C - Operator

D - Property

Answer : B

Explanation

Delegate − Used to declare a delegate.

Q 8 - Which of the following operator returns a Type object for the specified type?

A - AddressOf

B - Await

C - GetType

D - Function Expression

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.

Q 9 - Which of the following Collection class of VB.NET represents ordered collection of an object that can be indexed individually?

A - ArrayList

B - Hashtable

C - SortedList

D - Stack

Answer : A

Explanation

ArrayList − It represents ordered collection of an object that can be indexed individually. It is basically an alternative to an array. However, unlike array, you can add and remove items from a list at a specified position using an index and the array resizes itself automatically. It also allows dynamic memory allocation, add, search and sort items in the list.

Q 10 - Which of the following block of VB.NET identifies a block of code for which particular exceptions will be activated?

A - Try

B - Catch

C - Finally

D - Throw

Answer : A

Explanation

Try − A Try block identifies a block of code for which particular exceptions will be activated. It's followed by one or more Catch blocks.

vb.net_questions_answers.htm
Advertisements