3.4 Write Visual Basic statements that accomplish each of the following tasks:
a) Display the message "Hello" in resultTextBox.
ANS: resultTextBox.Text = "Hello"
b) Assign the product of hourlySalary and hoursWorked to variable earnings.
ANS: earnings = h
7.4 Write statements to accomplish each of the following tasks:
a) Display the value of element 6 of array numbers.
ANS: Console.WriteLine("Element 6 of numbers is cfw_0.", numbers(6)
b) Using a ForNext statement, assign the value 8 to each of the five el
5.8 Assume that nameTextBox is a TextBox and that otherCheckBox is a CheckBox next to which is
another TextBox called otherTextBox, in which the user should specify a value. What does this code
ANS: This code displays a message dialog only if
(Notepad GUI) Create the GUI for the notepad as shown in Fig. 2.1.
Fig. 2.1 | Notepad GUI.
a) Manipulating the Forms properties. Change the Text property of the Form to My Notepad. Change the Font property to 9pt Segoe UI .
6.14 (What Does This Code Do?) What does the following code do? Assume that this method is invoked
by using Mystery(70, 80).
ANS: This code calculates the average of two numbers. The user is informed of the average, but only if
the average is above 60. In