🧪 VB.Net MCQ Quiz Hub

VB.Net Mcq Question Set 1

Choose a topic to test your knowledge and improve your VB.Net skills

Who developed Visual Basic?





✅ Correct Answer: 3

Which of the following statement is used to define a class in visual basic?





✅ Correct Answer: 2

Which of the following extension is used to represent the project file in Visual Basic?





✅ Correct Answer: 1

If you keep a variable undeclared, it is automatically taken as to which of the following data type in Visual Basic?





✅ Correct Answer: 3

Which of the following applications can be developed using Visual Basic tool?





✅ Correct Answer: 1

In Visual Basic, which of the following is used for coding single-alternative and dual-alternative selection structures?





✅ Correct Answer: 2

What will be the output of the following Visual Basic code, If the intnumber variable is 110? If intnumber<=100 Then Intnumber=intnumber*2; Else Intnumber=intnumber*3; EndIf





✅ Correct Answer: 2

In the Visual Basic application, which of the following are listed in a properties window?





✅ Correct Answer: 3

What will be the output of the following Visual Basic expression? Financial.Pmt (0.05, 3, 9000)





✅ Correct Answer: 4

Which of the following is commonly used to perform an immediate action when clicked in Visual Studio?





✅ Correct Answer: 1

In the following Visual Basic code, what will be in msg, if str contains “visual basic”? Dim str as String Dim msg as String If str.toUpper=”VISUAL BASIC” msg=”VB.Net” Else msg=”Not Visual Basic” EndIf





✅ Correct Answer: 2

Which of the following displays the list of projects contained in the Visual Basic current solution?





✅ Correct Answer: 4

Which of the following method is used to sort an array in visual basic?





✅ Correct Answer: 1

Which of the following is the caption part for the following Visual Basic command? MessageBox.Show("Delete Visual Basic?","VB.Net",MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button2).





✅ Correct Answer: 3

Which of the following instruction tells the computer to close the current form in Visual Basic?





✅ Correct Answer: 2

Object respond to an event by writing ______





✅ Correct Answer: 4

What output will be returned if the following Visual Basic code is executed? strVisualBasic = "Sanfoundry, VB.Net" intCharIndex = strVisualBasic.IndexOf("VB")





✅ Correct Answer: 2

What will be the output of the following Visual Basic code? Dim intScores As Integer = {78, 83, 75, 90} Array.Reverse(intScores)





✅ Correct Answer: 2

Which of the following is used to write a stream of characters in Visual Basic?





✅ Correct Answer: 3

What is the value of len in the following Visual Basic code? Dim strVB() As String = {"Sanfoundry", "Visual Basic", "VB.Net", "Visual Studio"} Dim len As Integer len = strVB.Length()





✅ Correct Answer: 3

Which of the following is the default name assigned to the label control in Visual Basic?





✅ Correct Answer: 1

Which of the following toolbox is used to include an image on the Visual Basic form?





✅ Correct Answer: 2

In visual basic language what are the rules of a programming language called?





✅ Correct Answer: 3

What happens when both the minimize box and maximize box property are set to false in Visual Basic?





✅ Correct Answer: 1

In Visual Basic, which of the following keyword tells the computer to pass the variable’s address rather than its contents?





✅ Correct Answer: 3

Which of the following forces a literal constant to assume a data type other than the one its form indicates?





✅ Correct Answer: 3

Which of the following is used to display a message box in Visual Basic?





✅ Correct Answer: 1

In Visual Basic, which of the following method converts a string to a number?





✅ Correct Answer: 2

Which of the following is used to convert a number from one data type to another in visual studio?





✅ Correct Answer: 3

Which of the following type of constant is ControlChars.NewLine constant?





✅ Correct Answer: 3

The position of an item in a list box depends on which of the following property of the value stored in the list box’s?





✅ Correct Answer: 2

Which of the following returns a value after performing its specific task in Visual Basic?





✅ Correct Answer: 4

Which of the following property is used to specify a combo box’s style in Visual Basic?





✅ Correct Answer: 3

What will be the output of the following Visual Basic code? Dim intScores As Integer = {78, 83, 75, 90} Array.Sort(intScores)





✅ Correct Answer: 4

Which of the following section is used to make text appear around the image?





✅ Correct Answer: 1

If the properties of the form are not listed alphabetically, click __________ button to make it alphabetical.





✅ Correct Answer: 2

What is a class definition?





✅ Correct Answer: 2

What does namespace contain?





✅ Correct Answer: 1

Form is called as the _____





✅ Correct Answer: 2

Hungarian notations name are entered using ____





✅ Correct Answer: 1

Where does the form’s Text Property appear?





✅ Correct Answer: 1

What does the Start Position Property determine?





✅ Correct Answer: 1

The size property contains the size of ______





✅ Correct Answer: 1

The size property contains two numbers separated by comma, and a space. These numbers are ____





✅ Correct Answer: 1

Which is used to restore a property’s value?





✅ Correct Answer: 2

Who displays the list of projects contained in current solution?





✅ Correct Answer: 1

Who displays the item contained in each project?





✅ Correct Answer: 3

By which button you can display the additional items?





✅ Correct Answer: 2

A ____________ is a file that contains program instructions called code.





✅ Correct Answer: 1

Which box contains the name of the selected object?





✅ Correct Answer: 2