OOP Test 3

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

the displayed form must be closed before you can access other forms

All of the following are true of the Show method of a form except ________.

True

Any form in a Windows Forms application can be designated as the startup form.

Place the code for the functions in a module and add that module to each project.

What is the best way to share functions across more than one project?

You need to specify a negative step value in order to execute this loop.

What is wrong with the following code? Dim intIndex As Integer For intIndex = 5 To 1 ListBox.Items.Add(intIndex.ToString) Next

ShortcutKeys

What property must be set on a menu item to have the user activate that option by pressing Ctrl + C on the keyboard?

25

What value is assigned to lblSum.Text by the following code ? Dim intTotal As Integer = 0 For intOuter = 1 To 3 For intInner = intOuter To 3 intTotal += intOuter * intInner Next Next lblSum.Text = intTotal.ToString()

21

What will be the final value of intCount? Dim intCount As Integer = 3 Do intCount += 6 Loop While intCount < 20

Modal

When a ________ form is displayed, no other form in the application can receive the focus until the form is closed.

Checked

When a menu control's ________ property equals True, a check appears next to the menu item.

InputBox

Which of the following controls and methods provides a simple way to gather input from the user at runtime without placing a text box on a form?

mnuCopy.Enabled = False

Which of the following statements disables the Copy menu item named mnuCopy?

The Me keyword refers to the current instance of the form.

Which of the following statements most accurately describes the Me keyword?

This is an infinite loop.

Which statement is True in regard to the following code? intCount = 0 Do While intCount < 10 lstOutput.Items.Add("Good Job") Loop

Do While

Which type of loop repeats as long as its loop condition remains True?

Items.Count

To get the number of items stored in a ListBox, use the ________ property.

Control

A ToolTip is a ________ that allows the programmer to create a small popup message that displays when the user places the mouse over a control.

Nested Loop

A ________ is a loop inside another loop.

is shown when the user right-clicks a form or control

A context menu ________.

False

A context menu displays when the user double-clicks a control.

Integer Variable

A counter is a(n) ________ that can be incremented or decremented each time a loop runs.

Activated

A form's ________ event is triggered when the user switches to the form from another form or another application.

by hovering the mouse over the item

A menu item may be executed by a user in each of the following ways except ________.

Global

A module-level variable declared Public is also known as a ________ variable.

as public and class-level

A variable is accessible to statements outside the form if declared ________.

A scroll bar is automatically added when a ListBox contains more items than can be displayed.

How can you cause scroll bars to appear in a ListBox at runtime?

Type a hyphen (-) as a menu item's Text property.

How do you insert a separator bar into a menu?

It will display once.

How many times will the message I love Visual Basic be displayed? Dim intCount As Integer = 0 Do lstOutPut.Items.Add("I love Visual Basic") intCount += 1 Loop While intCount > 10

MenuStrip Control

In order to add a menu to a form, you must place a ________ on the form.

It causes intX to be incremented by 5 each time the loop repeats.

In the following statement that begins a For...Next loop, what is the purpose of the Step clause? For intX = 1 to 100 Step 5

True

Once you create a form, you do not have to re-create it to use it in another project.

Sorted

Setting this property to True will put the items in a ListBox in alphabetical order.

String

The InputBox function always returns a ________ value.

contains the text of the currently selected item

The SelectedItem property of a ListBox ________.

FormClosing

The ________ event occurs when a form is in the process of closing, but before it has closed.

Items.Insert

The ________ method can be used to place a new item at any position in a ListBox.

Items

The entries in a ListBox are stored in the ________ property.

0

The first item in a ListBox has an index of ________.

False

The last form created for a Windows Forms application is designated as the startup form.

most users expect to see these items

The primary reason to use standard menu items, such as File, Edit, and Help is ________.

Items.Clear

This method erases all the items in a ListBox.


संबंधित स्टडी सेट्स

BUS101 Quiz 6: Research methods for primary data: Part two - experimental research

View Set

Chapter 9: Teaching and Counseling

View Set

NURS 2207 Endocrine EAQ Quiz (Graded)

View Set

Veterinary Diseases (125) Midterm Practice Questions

View Set

Yes/No Questions (Est-ce que/ n'est-ce pas)

View Set