Visual Studio homework
1. Create a Visual Basic .NET Application – User Interface Elements (Lesson B Exercise 1, Zak, 2016, p. 83)
In this exercise, you will continue creating the Richardson County application from Module 2 Critical Thinking assignment Option 1. Open the VB2015\Chap02\Richardson Solution\Richardson Solution (Richardson Solution.sln) file. If necessary, open the designer window. Figure 2-18 (Zak, 2016) shows the completed interface.
· Add the missing txtAssessed and lblTax controls to the form.
· Set the lblTax control's TextAlign property to MiddleCenter. Lock the controls on the form. Assign the access keys (shown in the figure) to the text box and buttons.
· Set the TabIndex values appropriately. Save the solution and then start the application. Verify that the tab order is correct. Also verify that the access keys work appropriately. Use the Exit button to end the application.
Assignment Deliverables:
· The zip file containing the Visual Studio solution and project files.
2. Visual Basic .NET Application – Coding Exercise 1 (Exercise 13, Zak, 2016, p. 347)
For this coding exercise, write the Visual Basic code for a pretest loop that uses an Integer variable named intEven to display the even integers from 2 through 20 in the lblEven control.
· Use the For...Next statement.
· Display each number on a separate line in the control.
· Then create an application to test your code using the following names for the solution and project, respectively: Even Solution and Even Project.
· Save the application in the VB2015\ Chap06 folder.
· Add a button and a label to the interface. Enter your code in the button's Click event procedure, and then test the application appropriately.
Assignment Deliverables;
· The zip file containing the Visual Studio solution and project files.
3. Visual Basic .NET Application – Coding Exercise 2 (Exercise 6, Zak, 2016, p. 575)
An application contains the Structure statement shown here.
Structure MyFriend
Public strName As String
Public strBirthday As String
End Structure
· Create a VB.Net Windows Form application named MyFriend_YourName. Change the name property of your form to frmMain.
· Add the MyFriend Structure to the public class frmMain.
· Create 2 text boxes txtName and txtBirthday, and a button with the name property changed to btnExecute and the text property changed to Execute.
· In the button click event, write a Dim statement that declares a five-element one-dimensional array of MyFriend variables. Name the array home.
· Then write an assignment statement that assigns the value in the txtName control to the strName member contained in the last array element.
· Write an assignment statement that assigns the value in the txtBirthday control to the strBirthday member contained in the last array element.
· Set a breakpoint next to you’re the Dim statement of your home array. See page 829 in your text for how to set breakpoints in VB.Net or search online.
· Run your form, add a name and date to the respective text boxes and click the Execute button. Execution should stop at the breakpoint. Use the Debug menu or shortcut keys to step through the code. All code should execute without error.
Assignment Deliverables:
· The zip file containing the Visual Studio solution and project files.
4. CRITICAL THINKING ASSIGNMENT (60 points)
Complete the assignment below. Ensure that all of your assignment deliverables are attached before submitting your assignment.
Visual Basic .NET Application – Coding Exercise 3 (Exercise 13, Zack, 2016, p. 642)
For this coding exercise:
· Create an application that can be used to calculate the cost of installing a fence around a rectangular area.
· Create the application, using the following names for the solution and project, respectively: Fence Solution and Fence Project. Save the application in the VB2015\Chap11 folder.
· Use Windows to copy the Rectangle.vb file from the VB2015\Chap11 folder to the Fence Solution\Fence Project folder.
· Use the Project menu to add the Rectangle.vb class file to the project.
· Modify the class to use Double (rather than Integer) variables and properties.
· Add a method named GetPerimeter to the Rectangle class. The method should calculate and return the perimeter of a rectangle. To calculate the perimeter, the method will need to add together the length and width measurements, and then multiply the sum by 2.
· Create the interface shown in Figure 11-30 (zak, 2016). The image for the picture box is stored in the VB2015\Chap11\Fence.png file. Code the application and then test it appropriately. (Hint: Using 120 feet as the length, 75 feet as the width, and 10 as the cost per linear foot of fencing, the installation cost is $3,900.00.)
Assignment Deliverables:
· The zip file containing the Visual Studio solution and project files.
Posted Wed Dec 28, 2016 at 12:11 pm
5. CRITICAL THINKING ASSIGNMENT (60 points)
Complete the assignment below. Ensure that all of your assignment deliverables are attached before submitting your assignment.
Visual Basic .NET Application – Coding Exercise 4 (Exercise 2, Zak, 2016, p. 692)
In this exercise,
· Create an empty website application named Carnival and save it in the VB2015\ Chap12 folder.
· Add a new webpage named Default.aspx to the application. Change the DOCUMENT object's Title property to Brookfield.
· Create a webpage similar to the one shown in Figure 12-25. The image on the webpage is stored in the VB2015\ Chap12\Carnival.png file. (Hint: To position the image as shown in the figure, click the image, click Format on the menu bar, click Position, and then click the Left button in the Wrapping style section of the Position dialog box.)
· Save and then start the application. Close the browser window and then close the application.
Assignment Deliverables (The solution folder and project files should be in included in a zip [archive] file):
· The zip file containing the Visual Studio solution and project files.
Posted Wed Dec 28, 2016 at 12:11 pm