Vidyalelo
Computer Science · all questions

Visual Basic MCQs: Test Your Proficiency in Visual Basic Programming
practice.

Practice every MCQ with options. Use Show answers when you want the correct option and solution.

689

Questions

5/35

Page

Pick an option on a question to see the right answer and solution.

The main Property of check box is . . . . . . . .

Select an option to see the answer and solution.

What will contain in txtFirst after the following Visual Basic code is executed?

strName = "Penny Swanson"
txtFirst.Text = strName.Remove(5)

Select an option to see the answer and solution.

In VB, The . . . . . . . . first we check the condition, if the condition is true then it execute the true statement same as while condition .

Select an option to see the answer and solution.

A . . . . . . . . provides an area in the form for the user to enter data.

Select an option to see the answer and solution.

Which of the following is called the line continuation character?

Select an option to see the answer and solution.

Declaring a variable tell the computer to allocate a memory space that can be accessed by the variable name. The size of the memory space depends on?

Select an option to see the answer and solution.

A . . . . . . . . is defined as a zero or more characters enclosed in quotation marks.

Select an option to see the answer and solution.

What output will be returned if the following Visual Basic code is executed?

strCityState = "Nashville, TN"
blnIsContained = strCityState.Contains("TN")

Select an option to see the answer and solution.

In . . . . . . . . first we execute the true statement . then we check the condition if the condition is true then it again execute the true statement .

Select an option to see the answer and solution.

Which of the following expressions evaluates to True when the strPart variable contains the string "123X45"?

Select an option to see the answer and solution.

In VB, the. . . . . . . . is the function that computes the square root of a number.

Select an option to see the answer and solution.

In most applications, the code to define a user-defined data type is entered in the form's.

Select an option to see the answer and solution.

Variables declared in a form's declaration section have . . . . . . . . scope.

Select an option to see the answer and solution.

A structure variable named address contains a member variable named strStreet. Which of the following statements assigns the string "Maple" to the member variable?

Select an option to see the answer and solution.

ControlChars.NewLine constant is a . . . . . . . . constant.

Select an option to see the answer and solution.

Using array in a program is efficient because . . . . . . . .

Select an option to see the answer and solution.

. . . . . . . . function is used to format numbers.

Select an option to see the answer and solution.

Which is used to restore a property's value?

Select an option to see the answer and solution.

Writing data to a file is referred to as . . . . . . . .

Select an option to see the answer and solution.

The intNums array is declared as follows: Dim intNums() As Integer = {10, 5, 7, 2}. Which of the following blocks of code correctly calculates the average value stored in the array? The intTotal, intSub, and dblAvg variables contain the number 0 before the loops are processed.

Options are not available for this question.

Select an option to see the answer and solution.