0% found this document useful (0 votes)
2K views

Which Language Is Not A True Object-Oriented Programming Language?

This document contains 35 multiple choice questions about VB.Net. It tests knowledge of topics like object oriented programming concepts, features of the Visual Studio IDE, properties and events of common controls, and aspects of .NET like assemblies and authentication. The questions have a single correct answer that is explained after each one.

Uploaded by

laxmi bagade
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2K views

Which Language Is Not A True Object-Oriented Programming Language?

This document contains 35 multiple choice questions about VB.Net. It tests knowledge of topics like object oriented programming concepts, features of the Visual Studio IDE, properties and events of common controls, and aspects of .NET like assemblies and authentication. The questions have a single correct answer that is explained after each one.

Uploaded by

laxmi bagade
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 57

 

Vb.Net Mcq
1. Which language is not a true object-oriented programming
language?

A. VB 6 B. VB.NET

C. JAVA D. C++

Answer: A

2 . A GUI

A
uses buttons, menus, and icons
.

B.should be easy for a user to manipulate

C
both (a) and (b)
.

D
stands for Graphic Use Interaction
.

Answer & Explanation

Answer: C

3 . Visual Studio .NET provides which feature:

A
Debugging
.
B.application deployment

C
syntax checking
.

D
All of the above
.

Answer & Explanation

Answer: D

4 . What does IDE stand for?

A
Integrated Design Environment
.

B.Integrated Development Environment

C
Interior Design Environment
.

D
Interior Development Environment
.

Answer & Explanation

Answer: B

5 . Which type of project can a developer choose in the New Project


dialog box?
A
Visual Basic Projects
.

B.Visual C++ Projects

C
Visual C# Projects
.

D
All of the above
.

Answer & Explanation

Answer: D

6 . Which is not a main component of the Visual Studio IDE?

A. start menu B. Tool box

C. designer window D. Solution Explorer

Answer & Explanation


Answer: A

7 . Which does the solution explorer not display?

A. Form Properties B. Reference Folder

C. Form File D. Assemble File

Answer & Explanation

Answer: A
8 . Which is true about the name and text property of a control?

A
The text property changes to match any changes in the name property.
.

B.They are the same when the control is first created.

C
They are never the same unless the programmer makes it that way.
.

D
The name property changes to match any changes in the text property.
.

Answer & Explanation

Answer: B

9 . For which task does the IDE provide multiple ways to accomplish
the task?

A
Putting a control on the form
.

B.Running the program

C
Activating the property window for a control
.

D
All of the above
.

Answer & Explanation


Answer: D

10 . Which are the standard prefixes for the Button and Combo box
controls respectively?

A. bto and cbo B. bto and chb

C. btn and cbo D. btn and chb

Answer & Explanation

Answer: C

11 . Which are the standard prefixes for the text box and label controls respectively?

A. txb and lbl B. txb and lab

C. tex and lbl D. tex and lab

Answer & Explanation


Answer: A

Explanation:

txb and lbl


View Answer Workspace Report

12 . Which task is accomplished in the Code editor?

A
Adding forms to the project
.

B.Adding controls to the form

C
Adding controls to the title
.

D Adding event procedures to the form


.

Answer & Explanation

Answer: D

Explanation:

Adding event procedures to the form


View Answer Workspace Report

13 . Which is not a feature of a GUI that makes learning a program easy for users?

A
Detailed key strokes and commands
.

B.WYSIWYG formatting

C
Dialog boxes
.

D
Online help
.

Answer & Explanation

Answer: A

Explanation:

Detailed key strokes and commands


View Answer Workspace Report

14 . An object is composed of:

A. properties B. events
C. methods D. All of the above

Answer & Explanation

Answer: D

Explanation:

All of the above


View Answer Workspace Report

15 . Which statement about objects is true?

A
One class is used to create one object.
.

B.One class can create many objects.

C
One object is used to create one class.
.

D
One object can create many classes.
.

Answer & Explanation

Answer: B

Explanation:

One class can create many objects.


View Answer Workspace Report

16 . Which is not true about forms and controls in Visual Basic?

A
They are pre-built.
.

B.They are graphical objects.


C
Buttons can be created with the drag and drop method.
.

D
New versions of the classes must be created with each project.
.

Answer & Explanation


Answer: D

Explanation:

New versions of the classes must be created with each project.


View Answer Workspace Report

17 . Which is an example of Visual Basic Objects?

A. ASP.NET B. ADO.NET

C. Control objects D. All of the above

Answer & Explanation

Answer: D

Explanation:

All of the above


View Answer Workspace Report

18 . The .Net class library:

A
uses namespaces to manage all of the classes.
.

B.contains over 25,000 classes.


C
both (a) and (b)
.

D
has the System.Form namespace for classes used in Windows-based application.
.

Answer & Explanation

Answer: C

Explanation:

both (a) and (b)


View Answer Workspace Report

19 . Which is not a property of the Common control class?

A. Font B. show

C. ForeColor D. BackColor

Answer & Explanation

Answer: B

Explanation:

show
View Answer Workspace Report

20 . Which property determines whether a control is displayed to the user?

A. Visible B. Enabled
C. Show D. Hide

Answer & Explanation

Answer: A

Explanation:

Visible
View Answer Workspace Report

21 . The Button control can be activated:

A
by clicking the button with the mouse.
.

B.programmatically through the click event.

C
both (a) and (b)
.

D
with the form’s DefaultButton property.
.

Answer & Explanation


Answer: C

Explanation:

both (a) and (b)


View Answer Workspace Report

22 . The CancelButton property belongs to which object?

A. Form B. Button

C. Label D. TextBox

Answer & Explanation


Answer: A

Explanation:

Form
View Answer Workspace Report

23 . A click event procedure stud for the label control can be created by:

A
selecting the object and event from the code editor window’s drop-down boxes.
.

B.typing the code in the code editor window.

C
by double clicking the control.
.

D
All of the above
.

Answer & Explanation

Answer: D

Explanation:

All of the above


View Answer Workspace Report

24 . In event-driven programming an event is generated by:

A. the system B. a user’s action

C. the program itself D. All of the above

Answer & Explanation


Answer: D

Explanation:

All of the above


View Answer Workspace Report

25 . The Java and Visual Basic .NET belong to this type of programming language.

A
Assembly language
.

B.Machine language

C
High level programming language
.

D
Object oriented programming language
.

Answer & Explanation

Answer: A

Explanation:

Object oriented programming language


View Answer Workspace Report

26 . It is a comprehensive, object-oriented collection of reusable types that you can use to develop
applications.

A
Class Library
.

B.Solution Explorer

C
Properties Window
.
D
Windows Form Designer
.

Answer & Explanation


Answer: A

Explanation:

Class Library
View Answer Workspace Report

27 . It translates all high level instructions into machine code first before running the program.

A. Interpreter B. Compiler

C. Translator D. Language

Answer & Explanation

Answer: B

Explanation:

Compiler
View Answer Workspace Report

28 . A window that lists the solution name, the project name and all the forms used in the project.

A
Properties Window
.

B.Solution Explorer

C
Windows Form Designer
.

D Project Window
.

Answer & Explanation

Answer: B

Explanation:

Solution Explorer
View Answer Workspace Report

29 . VB.Net is

A. Platform Independent B. Compiler Language

C. Forward compatibale D. Backward compatible

Answer & Explanation

Answer: D

Explanation:

Backward compatible
View Answer Workspace Report

30 . VB.Net supports

A
Structured error handling
.

B.Unstructured error handling

C
Both
.
D
None
.

Answer & Explanation

Answer: A

Explanation:

Structured error handling


View Answer Workspace Report

31 . JIT stands for

A. Just In Type B. Just In Time

C. Just In Thread D. Just In Text

Answer & Explanation


Answer: B

Explanation:

Just In Time
View Answer Workspace Report

32 . Out of following which is NOT type of assembly?

A. Local B. Private

C. Public D. None

Answer & Explanation

Answer: A

Explanation:

Local
View Answer Workspace Report
33 . Assembly is ______grouping of all units

A. Arithmatical B. Logical

C. Physical D. Binary

Answer & Explanation

Answer: C

Explanation:

Physical
View Answer Workspace Report

34 . New keyword is used with the

A. Destructor B. Constructor

C. Both D. None

Answer & Explanation

Answer: B

Explanation:

Constructor
View Answer Workspace Report

35 . Keyword which is NOT used in VB.Net.

A. Int32 B. Int

C. Both D. None

Answer & Explanation


Answer: C

Explanation:

Both
View Answer Workspace Report
36 . Out of following,which is NOT a type of Authentication?

A
Windows Authentication
.

B.Web Authentication

C
Passport Authentication
.

D
Forms Authentication
.

Answer & Explanation


Answer: B

Explanation:

Web Authentication
View Answer Workspace Report

37 . What is CLR?

A
Current LanguageRuntime
.

B.Common Language Runtime

C
Common LanguageRealtime
.

D
Current LanguageRealtime
.
Answer & Explanation

Answer: B

Explanation:

Common Language Runtime 


View Answer Workspace Report

38 . IL stands for

A
Internal Language
.

B.Internet Language

C
Intermediate Language
.

D
Interpreted Language
.

Answer & Explanation

Answer: C

Explanation:

Intermediate Language
View Answer Workspace Report

39 . What is CTS?

A
Common Type Server
.

B.Control Type System


C
Common Type System
.

D
Control Type Server
.

Answer & Explanation

Answer: C

Explanation:

Common Type System


View Answer Workspace Report

40 . What is CLS?

A
Current Language Specifics
.

B.Common Language Specification

C
Common Language Specialization
.

D
Current Language System
.

Answer & Explanation

Answer: B

Explanation:

Common Language Specification


View Answer Workspace Report

41 . Language which is NOT supported by VB.Net


A. ASP B. COBOL

C. Perl D. C#

Answer & Explanation


Answer: A

Explanation:

ASP
View Answer Workspace Report

42 . What is used to store decimal data in .NET?

A. BinaryWriter B. DecimalWriter

C. OctalWriter D. HexaWriter

Answer & Explanation

Answer: A

Explanation:

BinaryWriter
View Answer Workspace Report

43 . Language which is NOT supported by .Net

A. Java B. VB

C. Perl D. COBOL

Answer & Explanation

Answer: A

Explanation:
Java
View Answer Workspace Report

44 . To declare an integer variable in VB.NET language, which one of the following statements is true?

A. Dim x As Integer B. x As Integer

C. Dim x As Single D. None of these

Answer & Explanation

Answer: A

Explanation:

Dim x As Integer
View Answer Workspace Report

45 . In VB.NET language, Which one is not the integer value?

A. 12 B. '23'

C. 10 D. 100

Answer & Explanation

Answer: B

Explanation:

'23'
View Answer Workspace Report

46 . Which of the following Loop structure does not supported by VB.Net?

A
Do ................ Loop
.
B.For ................... Next

C
Do ................ While
.

D
For Each ............ While
.

Answer & Explanation


Answer: C

Explanation:

Do ................ While
View Answer Workspace Report

47 . The _____ model does not offer a model for source code reuse.

A. COM+ B. DCOM

C. COM  D. .Net

Answer & Explanation

Answer: C

Explanation:

COM 
View Answer Workspace Report

48 . _____ allow custom items of information about a program element to be stored with an assembly's
metadata.

A. Properties B. Attributes 

C. Methods D. Classes
Answer & Explanation

Answer: B

Explanation:

Attributes 
View Answer Workspace Report

49 . The corresponding .Net FCL type for Short is ___________.

A. System.Int16  B. System.Int32 

C. System.Int64 D. None

Answer & Explanation

Answer: A

Explanation:

System.Int16 
View Answer Workspace Report

50 . The member "clear" of the Array class that sets a range of array elements to zero, false or null
reference is a _____________ method.

A. Method B. Class

C. Shared D. Object

Answer & Explanation

Answer: C

Explanation:
Shared
View Answer Workspace Report

51 . The ___________ method converts an OLE automation date value to a DateTime Instance.

A. Today B. Now

C. TimeOfDay D. FromOADate 

Answer & Explanation

Answer: D

Explanation:

FromOADate 

View Answer Workspace Report

52 . The function procedures are ___________ by default.

A. public B. private

C. protected D. inherited

Answer & Explanation

Answer: A

Explanation:

public

View Answer Workspace Report

53 . Every optional argument in the procedure definition must specify a _________ value which must be a
constant expression.

A. integer B. constant
C. default  D. character

Answer & Explanation

Answer: C

Explanation:

default 

View Answer Workspace Report

54 . Type casting in VB.Net is implemented by means of ____________ statement.

A. Type() B. TypeDef()

C. Btype() D. Ctype()

Answer & Explanation

Answer: D

Explanation:

Ctype()

View Answer Workspace Report

55 . Using a ________ variable does not enable us to create read-only properties that are often required by
a class.

A. private B. public

C. friend D. protected
Answer & Explanation

Answer: B

Explanation:

public

View Answer Workspace Report

56 . A ___________ performs invisible tasks even if you write no code.

A. destructor B. constructor 

C. function D. private method

Answer & Explanation

Answer: B

Explanation:

constructor 

View Answer Workspace Report

57 . The ___________________________________ does not describe inherited member functions,


inherited operators, and overridden virtual member functions.

A.Library

B.Objects

C. Classes

D
Class Library Reference 
.

Answer & Explanation

Answer: D
Explanation:

Class Library Reference 

View Answer Workspace Report

58 . The ______________________ group classes according to their common services.

A. Namespaces  B. inheritance

C. programs D. objects

Answer & Explanation

Answer: A

Explanation:

Namespaces 

View Answer Workspace Report

59 . Whenever an application is created, a ______ is added.

A. Class B. Object

C. Form  D. Property

Answer & Explanation

Answer: C

Explanation:

Form 

View Answer Workspace Report
60 . _________ are interactive objects that you place in dialog boxes or other windows to carry out user
actions.

A. Forms B. Controls 

C. Classes D. Objects

Answer & Explanation

Answer: B

Explanation:

Controls 

View Answer Workspace Report

61 . The _______________ class provides static methods to start, stop, or filter Windows messages in an
application.

A. Forms B. Control

C. Windows D. Application 

Answer & Explanation

Answer: D

Explanation:

Application 

View Answer Workspace Report

62 . The ___________is a systematic class framework used for the development of system tools and
utilities.

A..Net tools

B.Visual Basic 6
C. Visual Basic 2005

D
.Net Framework Class Library (FCL) 
.

Answer & Explanation

Answer: D

Explanation:

.Net Framework Class Library (FCL) 

View Answer Workspace Report

63 . The ______________ method converts the value of this instance to a double representing the OLE
automation date.

A. Now B. Today

C. TO OA Date D. From OA Date

Answer & Explanation

Answer: C

Explanation:

TO OA Date

View Answer Workspace Report

64 . The _________________ enable us to pass data between a program and a class.

A. Properties B. Procedures

C. Variables D. Functions
Answer & Explanation

Answer: A

Explanation:

Properties

View Answer Workspace Report

65 . Which of the following is a basic data type in VB.NET?

A. Boolean B. Byte

C. Char D. All of the above

Answer & Explanation

Answer: D

Explanation:

All of the above

View Answer Workspace Report

66 . Which of the following converts the expression to Object data type in VB.NET?

A. CSng(expression) B. CShort(expression)

C. CObj(expression) D. CSByte(expression)

Answer & Explanation

Answer: C

Explanation:

CObj(expression)

View Answer Workspace Report
67 . Which of the following accesss modifier specifies that an argument is passed in such a way that the
called procedure or property cannot change the value of a variable underlying the argument in the ca

A. ByVal B. ByRef

C. Friend D. Default

Answer & Explanation

Answer: A

Explanation:

ByVal

View Answer Workspace Report

68 . Which of the following accesss modifier specifies that an attribute at the beginning of a source file
applies to the current assembly module?

A. Key B. Module

C. Iterator D. In

Answer & Explanation

Answer: B

Explanation:

Module

View Answer Workspace Report

69 . Which of the following accesss modifier specifies that a property or procedure overrides an identically
named property or procedure inherited from a base class?
A. Overrides B. Overridable

C. ParamArray D. Partial

Answer & Explanation

Answer: A

Explanation:

Overrides − Specifies that a property or procedure overrides an identically named property or procedure
inherited from a base class.

View Answer Workspace Report

70 . Which of the following accesss modifier specifies that a property can be written but not read?

A. Widening B. WithEvents

C. WriteOnly D. ReadOnly

Answer & Explanation

Answer: C

Explanation:

WriteOnly − Specifies that a property can be written but not read.

View Answer Workspace Report

71 . Which of the following directive defines conditional compiler constants?

A. #Const B. #ExternalSource

C. #If...Then...#Else D. #Region

Answer & Explanation

Answer: A
Explanation:

#Const − This directive defines conditional compiler constants.

View Answer Workspace Report

72 . Which of the following directive conditionally compiles selected blocks of Visual Basic code?

A. #Const B. #ExternalSourc

C. #If...Then...#Else D. #Region

Answer & Explanation

Answer: C

Explanation:

#If...Then...#Else − This directive conditionally compiles selected blocks of Visual Basic code.

View Answer Workspace Report

73 . Which of the following property of Array class in VB.NET checks whether the Array has a fixed size?

A. IsFixedSize B. IsStatic

C. Length D. None of the above

Answer & Explanation

Answer: A

Explanation:

IsFixedSize gets a value indicating whether the Array has a fixed size.

View Answer Workspace Report
74 . 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 & Explanation

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.

View Answer Workspace Report

75 . Which of the following is correct about VB.NET?

VB.NET has complete support for object-oriented concepts. VB.NET has complete support for object-
A.
oriented concepts.

Everything in VB.NET is an object, including all of the primitive types (Short, Integer, Long, String,
B.
Boolean, etc.) and user-defined types, events, and even assemblies.

C. All objects inherits from the base class Object.

D
All of the above
.

Answer & Explanation

Answer: D

76 . Which of the following accesss modifier specifies that a procedure argument can be omitted when the
procedure is called?
A. NotOverridable B. Optional

C. Out D. Overloads

Answer & Explanation

Answer: B

Explanation:

Optional − Specifies that a procedure argument can be omitted when the procedure is called.

View Answer Workspace Report

77 . 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 & Explanation

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.

View Answer Workspace Report

78 . 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?

A. Dim B. Const

C. Enum D. Class
Answer & Explanation

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.

View Answer Workspace Report

79 . Which of the following directive is used for indicating a mapping between specific lines of source code
and text external to the source?

A. #Const B. #ExternalSource

C. #If...Then...#Else D. #Region

Answer & Explanation

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.

View Answer Workspace Report

80 . Which of the following operator declares the parameters and code that define a function lambda
expression?

A.AddressOf

B.Await

C. GetType
D
Function Expression 
.

Answer & Explanation

Answer: D

Explanation:

Function Expression − It declares the parameters and code that define a function lambda expression.

View Answer Workspace Report

81 . 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 & Explanation

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.

View Answer Workspace Report

82 . Which of the following block of VB.NET is used to execute a given set of statements, whether an
exception is thrown or not thrown?

A. Try B. Catch

C. Finally D. Throw
Answer & Explanation

Answer: C

Explanation:

Finally − The Finally block is used to execute a given set of statements, whether an exception is thrown or
not thrown. For example, if you open a file, it must be closed whether an exception is raised or not.

View Answer Workspace Report

83 . Which of the following converts the expression to String data type in VB.NET?

A. CStr(expression) B. CSByte(expression)

C. CShort(expression) D. CSng(expression)

Answer & Explanation

Answer: A

Explanation:

CStr(expression) − Converts the expression to String data type.

View Answer Workspace Report

84 . Which of the following accesss modifier is used in generic interfaces and delegates?

A. In B. Iterator

C. Key D. Module

Answer & Explanation


Answer: A

Explanation:

In − It is used in generic interfaces and delegates.

View Answer Workspace Report

85 . Which of the following accesss modifier specifies that a property or procedure cannot be overridden in a
derived class?

A. NotOverridable B. Optional

C. Out D. Overloads

Answer & Explanation

Answer: A

86 . Which of the following accesss modifier specifies that one or more declared programming elements are
accessible only from within their own class or from a derived class?

A. Private B. Public

C. Protected D. ReadOnly 

Answer & Explanation

Answer: C

Explanation:

Protected − Specifies that one or more declared programming elements are accessible only from within their
own class or from a derived class.

View Answer Workspace Report
87 . 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?

A. Shadows B. Shared

C. Static D. Unicode

Answer & Explanation

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.

View Answer Workspace Report

88 . Which of the following operator returns the address of a procedure?

A. AddressOf B. Await

C. GetType D. Function Expression

Answer & Explanation

Answer: A

Explanation:

AddressOf − Returns the address of a procedure.

View Answer Workspace Report

89 . Which of the following Collection class of VB.NET represents a first-in, first out collection of object?

A. Queue B. BitArray
C. SortedList D. Stack

Answer & Explanation

Answer: A

Explanation:

Queue − It represents a first-in, first out collection of object. It is used when you need a first-in, first-out
access of items. When you add an item in the list, it is called enqueue, and when you remove an item, it is
called deque.

View Answer Workspace Report

90 . Which of the following keyword of VB.NET is used to throw an exception when a problem shows up?

A. Try B. Catch

C. Finally D. Throw

Answer & Explanation

Answer: D

91 . Which of the following converts the expression to Char data type in VB.NET?

A. CBool(expression) B. CByte(expression)

C. CChar(expression) D. CDate(expression)

Answer & Explanation

Answer: C

Explanation:

CChar(expression) − Converts the expression to Char data type.


View Answer Workspace Report

92 . Which of the following converts the expression to Long data type in VB.NET?

A. CDbl(expression) B. CDec(expression)

C. CInt(expression) D. CLng(expression)

Answer & Explanation

Answer: D

Explanation:

CLng(expression) − Converts the expression to Long data type.

View Answer Workspace Report

93 . Which of the following accesss modifier specifies that a class cannot be used as a base class?

A. MustInherit B. MustOverride

C. Narrowing D. NotInheritable

Answer & Explanation

Answer: D

Explanation:

NotInheritable − Specifies that a class cannot be used as a base class.

View Answer Workspace Report

94 . Which of the following accesss modifier allows you to pass an arbitrary number of arguments to the
procedure?
A. Overridable B. Overrides

C. ParamArray D. Partial

Answer & Explanation

Answer: C

Explanation:

ParamArray − ParamArray allows you to pass an arbitrary number of arguments to the procedure. A
ParamArray parameter is always declared using ByVal.

View Answer Workspace Report

95 . 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?

A. Widening B. WithEvents

C. WriteOnly D. ReadOnly

Answer & Explanation

Answer: A

96 . Which of the following directive is used for indicating a mapping between specific lines of source code
and text external to the source?

A. #Const B. #ExternalSource

C. #If...Then...#Else D. #Region

Answer & Explanation


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.

View Answer Workspace Report

97 . Which of the following operator uses short-circuit evaluation to conditionally return one of two values?

A. If B. Await

C. GetType D. Function Expression

Answer & Explanation

Answer: A

Explanation:

If − It uses short-circuit evaluation to conditionally return one of two values. The If operator can be called
with three arguments or with two arguments.

View Answer Workspace Report

98 . Which of the following Collection class of VB.NET represents a last-in, first out collection of object?

A. ArrayList B. Hashtable

C. SortedList D. Stack

Answer & Explanation

Answer: D

Explanation:
Stack − It represents a last-in, first out collection of object. It is used when you need a last-in, first-out
access of items. When you add an item in the list, it is called pushing the item, and when you remove it, it is
called popping the item.

View Answer Workspace Report

99 . Which of the following is a true about Object in VB.NET?

A.Object variable size is 4 bytes on 32-bit platform

B.Object variable size is 8 bytes on 64-bit platform

C. Any type can be stored in a variable of type Object

D
All of the above
.

Answer & Explanation

Answer: D

Explanation:

All of the above

View Answer Workspace Report

100 . Which of the following converts the expression to Decimal data type in VB.NET?

A. CDbl(expression) B. CDec(expression)

C. CInt(expression) D. CLng(expression)

Answer & Explanation

Answer: B
101 . Which of the following accesss modifier specifies that an argument is passed in such a way that the
called procedure or property cannot change the value of a variable underlying the argument in the ca

A. ByRef B. ByVal

C. Default D. Friend

Answer & Explanation

Answer: B

Explanation:

ByVal − Specifies that an argument is passed in such a way that the called procedure or property cannot
change the value of a variable underlying the argument in the calling code.

View Answer Workspace Report

102 . Which of the following accesss modifier specifies that the type is covariant?

A. NotOverridable B. Optional

C. Out D. Overloads

Answer & Explanation

Answer: C

Explanation:

Out − For generic type parameters, the Out keyword specifies that the type is covariant.

View Answer Workspace Report

103 . Which of the following accesss modifier indicates that a class or structure declaration is a partial
definition of the class or structure?
A. Overridable B. Overrides

C. ParamArray D. Partial

Answer & Explanation

Answer: D

Explanation:

Partial − Indicates that a class or structure declaration is a partial definition of the class or structure.

View Answer Workspace Report

104 . Which of the following accesss modifier specifies that a property can be written but not read?

A. Widening B. WithEvents

C. WriteOnly D. ReadOnly

Answer & Explanation

Answer: C

Explanation:

WriteOnly − Specifies that a property can be written but not read.

View Answer Workspace Report

105 . Which of the following statement declares the operator symbol, operands, and code that define an
operator procedure on a class or structure?

A. Sub B. Declare

C. Operator D. Property
Answer & Explanation

Answer: C

106 . 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?

A. AddressOf B. Await

C. GetType D. Function Expression

Answer & Explanation

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.

View Answer Workspace Report

107 . Which of the following property of Array class in VB.NET gets the rank (number of dimensions) of the
Array?

A. Rank B. LongLength

C. Length D. None of the above

Answer & Explanation

Answer: A

Explanation:

Rank gets the rank (number of dimensions) of the Array.

View Answer Workspace Report
108 . Which of the following block of VB.NET identifies a place to catch an exception with an exception
handler at the place in a program where you want to handle the problem?

A. Try B. Catch

C. Finally D. Throw

Answer & Explanation

Answer: B

Explanation:

Catch − A program catches an exception with an exception handler at the place in a program where you
want to handle the problem. The Catch keyword indicates the catching of an exception.

View Answer Workspace Report

109 . Which of the following converts the expression to Long data type in VB.NET?

A. CDbl(expression) B. CDec(expression)

C. CInt(expression) D. CLng(expression)

Answer & Explanation

Answer: D

Explanation:

CLng(expression) − Converts the expression to Long data type.

View Answer Workspace Report

110 . Which of the following accesss modifier specifies that one or more declared programming elements are
accessible from within the assembly that contains their declaration, not only by the component that

A. ByRef B. ByVal
C. Default D. Friend

Answer & Explanation

Answer: D

106 . 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?

A. AddressOf B. Await

C. GetType D. Function Expression

Answer & Explanation

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.

View Answer Workspace Report

107 . Which of the following property of Array class in VB.NET gets the rank (number of dimensions) of the
Array?

A. Rank B. LongLength

C. Length D. None of the above

Answer & Explanation


Answer: A

Explanation:

Rank gets the rank (number of dimensions) of the Array.

View Answer Workspace Report

108 . Which of the following block of VB.NET identifies a place to catch an exception with an exception
handler at the place in a program where you want to handle the problem?

A. Try B. Catch

C. Finally D. Throw

Answer & Explanation

Answer: B

Explanation:

Catch − A program catches an exception with an exception handler at the place in a program where you
want to handle the problem. The Catch keyword indicates the catching of an exception.

View Answer Workspace Report

109 . Which of the following converts the expression to Long data type in VB.NET?

A. CDbl(expression) B. CDec(expression)

C. CInt(expression) D. CLng(expression)

Answer & Explanation

Answer: D

Explanation:

CLng(expression) − Converts the expression to Long data type.

View Answer Workspace Report
110 . Which of the following accesss modifier specifies that one or more declared programming elements are
accessible from within the assembly that contains their declaration, not only by the component that

A. ByRef B. ByVal

C. Default D. Friend

Answer & Explanation

Answer: D

111 . Which of the following accesss modifier specifies that one or more declared local variables are to
continue to exist and retain their latest values after termination of the procedure in which they are

A. Shadows B. Shared

C. Static D. Unicode

Answer & Explanation

Answer: C

Explanation:

Static − Specifies that one or more declared local variables are to continue to exist and retain their latest
values after termination of the procedure in which they are declared.

View Answer Workspace Report

112 . 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?

A. Widening B. WithEvents
C. WriteOnly D. ReadOnly

Answer & Explanation

Answer: B

Explanation:

WithEvents − Specifies that one or more declared member variables refer to an instance of a class that can
raise events.

View Answer Workspace Report

113 . Which of the following statement declares a user-defined event?

A. Event B. Delegate

C. Operator D. Property

Answer & Explanation

Answer: A

Explanation:

Event − Declares a user-defined event.

View Answer Workspace Report

114 . Which of the following Collection class of VB.NET represents a first-in, first out collection of object?

A. Queue B. BitArray

C. SortedList D. Stack

Answer & Explanation


Answer: A

Explanation:

Queue − It represents a first-in, first out collection of object. It is used when you need a first-in, first-out
access of items. When you add an item in the list, it is called enqueue, and when you remove an item, it is
called deque.

View Answer Workspace Report

115 . Which of the following Collection class of VB.NET represents an array of the binary representation
using the values 1 and 0?

A. Queue B. BitArray

C. SortedList D. Stack

Answer & Explanation

Answer: B

116 . Which of the following converts the expression to Boolean data type in VB.NET?

A.CBool(expression)

B.CByte(expression)

C. CChar(expression)

D
CDate(expression) 
.

Answer & Explanation

Answer: A
Explanation:

CBool(expression) − Converts the expression to Boolean data type.

View Answer Workspace Report

117 . Which of the following converts the expression to SByte data type in VB.NET?

A. CObj(expression) B. CSByte(expression)

C. CShort(expression) D. CSng(expression)

Answer & Explanation

Answer: B

Explanation:

CSByte(expression) − Converts the expression to SByte data type.

View Answer Workspace Report

118 . Which of the following accesss modifier specifies that an argument is passed in such a way that the
called procedure or property cannot change the value of a variable underlying the argument in the ca

A. ByRef B. ByVal

C. Default D. Friend

Answer & Explanation

Answer: B

Explanation:

ByVal − Specifies that an argument is passed in such a way that the called procedure or property cannot
change the value of a variable underlying the argument in the calling code.

View Answer Workspace Report
119 . 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 b

A. Ansi B. Assembly

C. Async D. Auto

Answer & Explanation

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.

View Answer Workspace Report

120 . Which of the following accesss modifier specifies that a property or procedure redeclares one or more
existing properties or procedures with the same name?

A. NotOverridable B. Optional

C. Out D. Overloads

Answer & Explanation

Answer: D

121 . Which of the following statement declares an enumeration and defines the values of its members?

A. Dim B. Const

C. Enum D. Class

Answer & Explanation


Answer: C

Explanation:

Enum − Declares an enumeration and defines the values of its members.

View Answer Workspace Report

122 . Which of the following property of Array class in VB.NET checks whether the Array is readonly?

A. IsFixedSize B. IsReadOnly

C. Length D. None of the above

Answer & Explanation

Answer: B

You might also like