New Semester
Started
Get
50% OFF
Study Help!
--h --m --s
Claim Now
Question Answers
Textbooks
Find textbooks, questions and answers
Oops, something went wrong!
Change your search query and then try again
S
Books
FREE
Study Help
Expert Questions
Accounting
General Management
Mathematics
Finance
Organizational Behaviour
Law
Physics
Operating System
Management Leadership
Sociology
Programming
Marketing
Database
Computer Network
Economics
Textbooks Solutions
Accounting
Managerial Accounting
Management Leadership
Cost Accounting
Statistics
Business Law
Corporate Finance
Finance
Economics
Auditing
Tutors
Online Tutors
Find a Tutor
Hire a Tutor
Become a Tutor
AI Tutor
AI Study Planner
NEW
Sell Books
Search
Search
Sign In
Register
study help
computer science
programming with microsoft visual basic 2015
Bundle Programming With Microsoft Visual Basic 2015 7th + Mindtap Programming 1 Term Printed Access Card 7th Edition Diane Zak - Solutions
19. In this exercise, you learn how to use a text box’s CharacterCasing property. Open the VB2015\Chap04\CharCase Solution\CharCase Solution (CharCase Solution.sln) file.a. Open the Code Editor window and study the code contained in the btnDisplay_Click procedure. The code compares the contents
18. In this exercise, you modify the commission application from Exercise 17. Use Windows to make a copy of the Commission Solution folder. Rename the copy Modified Commission Solution. Open the Commission Solution (Commission Solution.sln) file contained in the Modified Commission Solution folder.
17. Create an application that displays a salesperson’s monthly commission amount, given his or her monthly sales amount and commission ID. Salespeople who have one of the following commission IDs receive a 15% commission: A1, B2, C3. All other salespeople receive a 12% commission. Use the
16. In this exercise, you modify the Sam’s Paper Shoppe application from Exercise 12. Use Windows to make a copy of the Sam Solution folder. Rename the copy Modified Sam Solution. Open the Sam Solution (Sam Solution.sln) file contained in the Modified Sam Solution folder. Change the code to give
15. Create an application that determines whether a customer is entitled to free shipping when ordering from JimJoe’s Web site. JimJoe’s does not charge shipping on any order when the customer belongs to the JimJoe’s Free Shipping Club. It also doesn’t charge shipping for any order totaling
14. Create an application that determines whether a customer is entitled to free shipping when ordering from Savannah’s Web site. Savannah’s does not charge shipping when the customer uses his or her Savannah’s credit card to pay for an order totaling $100 or more. Customers who do not meet
13. Create an application that displays a salesperson’s annual bonus amount, given his or her annual sales amount. The bonus rate is 10% when the sales amount is at least$25,000; otherwise, the bonus rate is 8%. Use the following names for the solution and project, respectively: Bonus Solution
12. Sam’s Paper Shoppe wants you to create an application that allows a salesclerk to enter an item’s price and the quantity purchased by a customer. When the quantity purchased is greater than 5, the customer is given a 15% discount. The application should display the total amount the customer
11. In this exercise, you modify one of the Gross Pay Calculator applications from the lesson. Use Windows to make a copy of the Gross Solution-Dual folder. Rename the copy Modified Gross Solution-Dual. Open the Gross Solution (Gross Solution.sln)file contained in the Modified Gross Solution-Dual
10. In this exercise, you modify the Net Income or Loss application from the lesson. Use Windows to make a copy of the Net Solution folder. Rename the copy Modified Net Solution. Open the Net Solution (Net Solution.sln) file contained in the Modified Net Solution folder. Locate the btnCalc_Click
9. In this exercise, you modify one of the Gross Pay Calculator applications from the lesson. Use Windows to make a copy of the Gross Solution-Single folder. Rename the copy Modified Gross Solution-Single. Open the Gross Solution (Gross Solution.sln)file contained in the Modified Gross
8. A procedure should calculate a 2.5% commission when the strCommType variable contains the string “Prime” (in any case); otherwise, it should calculate a 2%commission. The commission is calculated by multiplying the commission rate by the contents of the dblSales variable. Display the
7. Write an If...Then...Else statement that displays the string “Cat” in the lblAnimal control when the strAnimal variable contains the letter “C” (in any case); otherwise, display the string “Dog”. Also draw the flowchart.
6. Write an If...Then...Else statement that displays the value 25 in the lblShipping control when the strState variable contains the string “Alaska” (in any case); otherwise, display the value 15.
5. Write an If...Then...Else statement that assigns the number 35 to the intCommission variable when the decSales variable contains a number that is less than or equal to$250; otherwise, assign the number 50.
4. Write an If...Then...Else statement that displays the string “Time to reorder” in the lblMsg control when the intInStock variable contains a number that is less than 250;otherwise, display the string “We have enough in stock”.
3. Write an If...Then...Else statement that displays the string “Incorrect quantity” in the lblMsg control when the intQuantity variable contains a number that is less than 0;otherwise, display the string “Valid quantity”.
2. Write an If...Then...Else statement that displays the string “Please enter ZIP code” in the lblMsg control when the txtZip control does not contain any data.
1. Write an If...Then...Else statement that displays the string “Columbia” in the lblCapital control when the txtState control contains the string “SC” (in any case).
11. The expression 5 * 4 > 6 ˆ 2 AndAlso True OrElse False evaluates to _____________________.a. Trueb. False
10. The expression 5 * 4 > 6 ˆ 2 evaluates to _____________________.a. Trueb. False
9. The expression 7 + 3 * 2 > 5 * 3 AndAlso True evaluates to _____________________.a. Trueb. False
8. The expression 8 >= 4 + 6 OrElse 5 > 6 AndAlso 4 < 7 evaluates to _____________________.a. Trueb. False
7. The expression 6 + 3 > 7 AndAlso 11 > 2 * 5 evaluates to _____________________.a. Trueb. False
6. The expression 6 > 12 OrElse 4 < 5 evaluates to _____________________.a. Trueb. False
5. An expression can contain arithmetic, comparison, and logical operators. Indicate the order of precedence for the three types of operators by placing a number (1, 2, or 3) on the line to the left of the operator type._____________________ Arithmetic _____________________ Logical
4. The six logical operators are listed below. Indicate their order of precedence by placing a number (1, 2, and so on) on the line to the left of the operator. If two or more operators have the same precedence, assign the same number to each._____________________ Xor _____________________ And
3. Which of the following If clauses should you use to compare the string contained in the txtId control with the state abbreviation CA?a. If txtId.Text = ToUpper(“CA”) Thenb. If txtId.Text = ToLower(“ca”) Thenc. If txtId.Text.ToUpper = “CA” Thend. If ToUpper(txtId.Text) = “CA” Then
2. Which of the following compound conditions can be used to determine whether the value in the intQuantity variable is outside the range of 0 through 500?a. intQuantity < 0 OrElse intQuantity > 500b. intQuantity > 0 AndAlso intQuantity < 500c. intQuantity = 500d. intQuantity < 0 AndAlso
1. An If...Then...Else statement in the btnCalc_Click procedure declares a variable in its false path. Where can the variable be used?a. in the entire Code Editor windowb. in the entire btnCalc_Click procedurec. in both paths in the If...Then...Else statementd. only in the false path in the
11. Open the VB2015\Chap03\Debug Solution-Lesson C\Debug Solution (Debug Solution.sln) file. Start and then test the application. Locate and correct any errors.
10. Create an application using the following names for the solution and project, respectively: Pink Elephant Solution and Pink Elephant Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. The application’s
9. Create an application using the following names for the solution and project, respectively:Credit Card Solution and Credit Card Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. Create an interface that
8. Create an application using the following names for the solution and project, respectively: Pennies Solution and Pennies Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. Create an interface that allows
7. In this exercise, you modify the Chopkins Toys application from Exercise 2. Use Windows to make a copy of the Chopkins Solution folder. Rename the copy Modified Chopkins Solution. Open the Chopkins Solution (Chopkins Solution.sln) file contained in the Modified Chopkins Solution folder. Modify
6. Create an application using the following names for the solution and project, respectively: Retirement Solution and Retirement Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. Pamela receives 52 weekly
5. Create an application using the following names for the solution and project, respectively:Van Solution and Van Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. Rent-A-Van wants you to create an
4. In this exercise, you modify the bakery application from this lesson. Use Windows to make a copy of the Bakery Solution folder. Rename the copy Modified Bakery Solution-Lesson C-Intermediate. Open the Bakery Solution (Bakery Solution.sln) file contained in the Modified Bakery Solution-Lesson
3. Create an application using the following names for the solution and project, respectively:Tile Solution and Tile Project. Save the application in the VB2015\Chap03 folder.Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. The manager of Tile Unlimited wants you
2. Create an application using the following names for the solution and project, respectively: Chopkins Solution and Chopkins Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb. Change the form’s name to frmMain. Create the interface shown in
1. In this exercise, you modify the bakery application from this lesson. Use Windows to make a copy of the Bakery Solution folder. Rename the copy Modified Bakery Solution-Lesson C-Intro. Open the Bakery Solution (Bakery Solution.sln) file contained in the Modified Bakery Solution-Lesson C-Intro
5. Which of the following statements declares a procedure-level variable that retains its value after the procedure in which it is declared ends?a. Const intCounter As Integerb. Dim intCounter As Constantc. Dim intCounter As Integerd. Static intCounter As Integer
4. Which of the following statements declares a procedure-level variable that is removed from the computer’s memory when the procedure ends?a. Const intCounter As Integerb. Dim intCounter As Integerc. Local intCounter As Integerd. Static intCounter As Integer
3. Which of the following clauses associates a procedure with the TextChanged event of the txtMid and txtFinal controls?a. Associates txtMid_TextChanged, txtFinal_TextChangedb. Handled txtMid_TextChanged, txtFinal_TextChangedc. Controls txtMid.TextChanged And txtFinal.TextChangedd. Handles
2. A _____________________ variable is a procedure-level variable that retains its value after the procedure in which it is declared ends.a. constantb. staticc. stationaryd. term
1. Which of the following events occurs when a change is made to the contents of a text box?a. Changeb. Changedc. TextChangedd. TextChange
12. In this exercise, you will learn about a form’s CancelButton property, which specifies the button whose Click event procedure is processed when the user presses the Esc key.Open the VB2015\Chap03\Cancel Solution\Cancel Solution (Cancel Solution.sln) file.a. Open the Code Editor window and
11. Create an application that displays a circle’s area and circumference, given its radius.Use the following names for the solution and project, respectively: Circle Solution and Circle Project. Save the application in the VB2015\Chap03 folder. Change the form file’s name to Main Form.vb.
10. K & L Clothiers wants you to create an application that prints a customer’s sales receipt.A sample receipt is shown in Figure 3-49. Use the following names for the solution and project, respectively: Clothiers Solution and Clothiers Project. Save the application in the VB2015\Chap03
9. The strFirst, strMiddle, strLast, and strNickname variables contain the strings “Addison”, “Grace”, “Carson”, and “Addi G”, respectively. Write an assignment statement that will display the string “My name is Addison Grace Carson, but you can call me Addi G.” in the lblMsg
8. The strCity and strState variables contain the strings “Scottsdale” and “AZ”, respectively. Write an assignment statement to display the string “They live in Scottsdale, AZ.” in the lblMsg control.
7. The strFirst and strLast variables contain the strings “Kate” and “Juarez”, respectively. Write an assignment statement to display the string “Kate Juarez” in the lblName control.
6. In this exercise, you modify the bakery application from this lesson. Use Windows to make a copy of the Bakery Solution folder. Rename the copy Modified Bakery Solution-Lesson B. Open the Bakery Solution (Bakery Solution.sln) file contained in the Modified Bakery Solution-Lesson B folder. Modify
5. In this exercise, you modify the bonus application from Exercise 4. Use Windows to make a copy of the Bonus Solution folder. Rename the copy Modified Bonus Solution.Open the Bonus Solution (Bonus Solution.sln) file contained in the Modified Bonus Solution folder. Code the frmMain_Load event so
4. Open the VB2015\Chap03\Bonus Solution\Bonus Solution (Bonus Solution.sln) file.The application displays a salesperson’s total sales and bonus amounts. The bonus is calculated by multiplying the total sales by 10%. Make the Calculate button the default button. Open the Code Editor window and
3. This exercise assumes you have completed the Cranston Berries application from Exercise 3 in each of Chapter 2’s lessons. Use Windows to copy the Cranston Solution folder from the VB2015\Chap02 folder to the VB2015\Chap03 folder, and then open the Cranston Solution (Cranston Solution.sln)
2. This exercise assumes you have completed the Jordan Sports Store application from Exercise 2 in each of Chapter 2’s lessons. Use Windows to copy the Jordan Solution folder from the VB2015\Chap02 folder to the VB2015\Chap03 folder, and then open the Jordan Solution (Jordan Solution.sln) file.
1. This exercise assumes you have completed the Richardson County application from Exercise 1 in each of Chapter 2’s lessons. Use Windows to copy the Richardson Solution folder from the VB2015\Chap02 folder to the VB2015\Chap03 folder, and then open the Richardson Solution (Richardson
10. If the decPay variable contains the number 1200.76, which of the following statements displays the number as 1,200.76?a. lblPay.Text = decPay.ToString("C2")b. lblPay.Text = decPay.ToString("F2")c. lblPay.Text = decPay.ToString("D2")d. lblPay.Text = decPay.ToString("N2")
9. The InputBox function’s prompt argument should be entered using which type of capitalization?a. book titleb. sentence
8. Which of the following statements correctly assigns the InputBox function’s return value to a String variable named strCity?a. String.TryParse(InputBox(strMSG, "City"), strCity)b. strCity = String.TryParse(InputBox(strMSG, "City"))c. strCity = InputBox(strMSG, "City")d. none of the above
7. Which of the following statements correctly assigns the InputBox function’s return value to a Double variable named dblNum?a. Double.TryParse(InputBox(strMSG, "Number"), dblNum)b. dblNum = Double.TryParse(InputBox(strMSG, "Number"))c. dblNum = InputBox(strMSG, "Number")d.
6. The strCity and strState variables contain the strings “Louisville” and “KY”, respectively. Which of the following will display the string “Louisville, KY” (the city, a comma, a space, and the state) in the lblCityState control?a. lblCityState.Text = strCity & ', ' & strStateb.
5. The strWord1 and strWord2 variables contain the strings “Input” and “Box”, respectively. Which of the following will display the string “InputBox” (one word) in the lblWord control?a. lblWord.Text = strWord1 & strWord2b. lblWord.Text = "strWord1" & "strWord2"c. lblWord.Text =
4. Which of the following Visual Basic constants advances the insertion point to the next line?a. Advanceb. ControlChars.Advancec. ControlChars.NewLined. none of the above
3. Which of the following is the concatenation operator?a. @b. &c. $d. #
2. The InputBox function displays a dialog box containing which of the following?a. input areab. OK and Cancel buttonsc. promptd. all of the above
1. The name of a form’s default button is specified in the _____________________ property.a. button’s AcceptButtonb. button’s DefaultButtonc. form’s AcceptButtond. form’s DefaultButton
19. Open the VB2015\Chap03\Debug Solution-Lesson A\Debug Solution (Debug Solution.sln)file. The application is supposed to display the number of times the Count button is pressed, but it is not working correctly.a. Start the application. Click the Count button. The message indicates that you have
18. In this exercise, you experiment with procedure-level and class-level variables.Open the VB2015\Chap03\Scope Solution\Scope Solution (Scope Solution.sln)file. The application allows the user to calculate either a 5% or 10% commission on a sales amount. It displays the sales and commission
17. Open the VB2015\Chap03\Width Solution\Width Solution (Width Solution.sln)file. The application calculates a rectangle’s width, given its perimeter and length.In the General Declarations section of the Code Editor window, enter your name, the current date, and the three Option statements. Use
16. Open the VB2015\Chap03\Floor Solution\Floor Solution (Floor Solution.sln) file. The application displays the area of a floor in square yards, given its length and width (both measured in feet). In the General Declarations section of the Code Editor window, enter your name, the current date, and
15. Write the statement to declare a Double variable that can be used by two procedures in the same form. Name the variable dblNetIncome. Also specify where you will need to enter the statement in the Code Editor window and whether the variable is a procedure-level or class-level variable.
14. Write an assignment statement that adds together the values stored in the decDomestic and decInternational variables and then assigns the result to a String variable named strIncome.
13. Write an assignment statement that increases the contents of the decPrice variable by 2%.
12. Open the VB2015\Chap03\Tax Solution\Tax Solution (Tax Solution.sln) file. The application displays a 5% sales tax on the purchase amount entered by the user. In the General Declarations section of the Code Editor window, enter your name, the current date, and the three Option statements. Use
11. Open the VB2015\Chap03\Mileage Solution\Mileage Solution (Mileage Solution.sln)file. The application displays the miles per gallon, given the miles driven and gallons used. In the General Declarations section of the Code Editor window, enter your name, the current date, and the three Option
10. Write an assignment statement that subtracts the contents of the dblExpenses variable from the contents of the dblIncome variable and then assigns the result to the dblNet variable.
9. Write a Private statement to declare a class-level variable named dblGrandTotal.
8. Write the statement to assign the contents of the dblTotalSales variable to the lblTotal control.
7. Write the statement to store the contents of the txtAge control in an Integer variable named intAge.
6. Write the statement to declare the procedure-level decINTEREST_RATE named constant whose value is 0.075.
5. Write an assignment statement that assigns the name Carol Jones to a String variable named strEmployee. Also write assignment statements that assign the numbers 34 and 15.99 to variables named intAge and dblPayRate, respectively.
4. Write an assignment statement that assigns Georgia to a String variable named strState.
3. A procedure needs to store the name of a business, the number of its employees at the beginning of the current year, the number of new employees hired during the current year, the number of employees who left the business during the current year, and the number of its employees at the end of the
2. A procedure needs to store a person’s height and weight. The height may have a decimal place; the weight will always be a whole number. Write the appropriate Dim statements to declare the necessary procedure-level variables.
1. A procedure needs to store a salesperson’s name and bonus amount (which may have decimal places). Write the appropriate Dim statements to declare the necessary procedure-level variables.
12. A static variable has the same _____________________ as a procedure-level variable but the same _____________________ as a class-level variable.a. lifetime, scopeb. scope, lifetime
11. Which of the following statements prevents data loss due to implicit type conversions?a. Option Explicit Onb. Option Strict Onc. Option Implicit Offd. Option Convert Off
10. If Option Strict is set to On, which of the following statements assigns the sum of two Integer variables to the Text property of the lblTotal control?a. lblTotal.Text = Convert.ToInteger(intN1 + intN2)b. lblTotal.Text = Convert.ToInt32(intN1 + intN2)c. lblTotal.Text = Convert.ToString(intN1) +
9. Which of the following declares a named constant having the Double data type?a. Const dblRATE As Double = 0.09b. Const dblRATE As Doublec. Constant dblRATE = 0.09d. both a and b
8. If Option Strict is set to On, which of the following statements will assign the contents of the txtSales control to a Double variable named dblSales?a. dblSales = txtSales.Textb. dblSales = txtSales.Text.Convert.ToDoublec. Double.TryParse(txtSales.Text, dblSales)d.
7. Which of the following are computer memory locations that can temporarily store information?a. literal constantsb. named constantsc. variablesd. both b and c
6. Which of the following declares a procedure-level String variable?a. Dim String strCityb. Dim strCity As Stringc. Private strCity As Stringd. both b and c
5. Which of the following statements declares a class-level variable?a. Class intNum As Integerb. Private intNum As Integerc. Private Class intNum As Integerd. Private Dim intNum As Integer
4. Which of the following keywords can be used to declare a variable within a procedure?a. Dimb. Procedurec. Staticd. both a and c
3. Which of the following statements declares a procedure-level variable that remains in the computer’s memory until the application ends?a. Dim Static intScore As Integerb. Private Static intScore As Integerc. Static intScore As Integerd. both b and c
2. Which of the following is a data item whose value does not change during run time?a. literal constantb. literal variablec. named constantd. variable
1. Which of the following keywords is used to declare a class-level variable?a. Classb. Dimensionc. Globald. Private
12. Open the VB2015\Chap02\Debug Solution\Debug Solution (Debug Solution.sln) file.Locate and then correct the syntax errors in the Code Editor window. Save the solution, and then start and test the application.
Showing 600 - 700
of 1847
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Last
Step by Step Answers