A. Lab # CIS CIS170A-A3
B. Lab 3 of 7: Decisions
C. Lab Overview – Scenario / Summary:
4. Given a set of program specifications for a simple business problem requiring one or more decisions, code and test a program that meets the specifications and employs best programming practices.
6. Given a program with syntax and logic errors, employ the debugger and other diagnostic tools to remove or correct the errors.
This lab will familiarize students with If/Else/EndIf statements and possible Select Cast statements by calculating the amount of money a drive-in movie theater makes in a single night.
Step 6 Deliverable Points
6 Program Listing, Output, and Project Files 45
The Dropbox deliverables include the following.
1. Include a zipped file with all the files from your Visual Basic project (see directions in Doc Sharing on how to collect and zip files).
2. Create a single MS Word document and include the following.
• For each lab, copy and paste your code directly into the MS Word file.
• Include screenshot(s) of your test data with test results. Enter enough data to demonstrate that all your code has been tested.
• Include another screenshot of the Visual Basic build output messages. Check your build output to make sure you have a successful build with (0) errors and (0) warnings. NOTE: The build output messages appear at the bottom of your window after you click the Build menu and before you click the Start Without Debugging option. Your build output messages provide a list of compiler warnings or errors and let you know whether your program compiled successfully.
• Include the Word document as part of the zipped project file.
3. Upload each part of the lab into its corresponding weekly Dropbox.
E. Lab Steps:
Step 1: Create a New Project
Create a new project in VB.NET. Name your project CIS170A_Lab03.
Step 2: Program Description
In this program you will create a Windows Form application that will calculate and display the money made by a drive-in movie theater each night. The movie theater has two types of nights. A “Regular” night is where each person in a guest car has to buy a ticket, and each ticket costs $10. A “Car” night is a special promotion where there is one price per car of $15, no matter how many guests are in the car.
In addition to the cost of entry (either Regular or Car), the theater sells popcorn and candy but the price of the items depends on the type of night. On a Regular night popcorn costs $1.50 per box and on a special Car night popcorn costs $2.00 per box. On a Regular night candy cost $2.25 per candy box, while on a special Car night candy cost $3.00 per box.
On any night, the maximum number of cars allowed in is 500 and the maximum number of individual tickets is 3,000; the theater can produce 4,500 bags of popcorn each night and has 4,000 candy items.
Once the total sales are calculated, the program will display a summary message with the type of night, the total number of cars, the total ticket sales, the total popcorn sales, the total candy sales, and the total sales amount.
Use the following flowchart to process the amount of money made by the theater each night.
Step 3: Build the Form
The following is the Object, Property, Setting, Event chart for the form controls, and each input field will have a label/input field pair. You should group the related information in the associated group box.
The form and form controls will be logically placed on the form, the controls aligned and sized, and a logical tab order assigned to each of the form controls.
Object Property Setting
frmSalesData Text Movie Theater Sales Data
lblHeading Text Name, Course Title, Week Number, Lab Title
grpNightType Text Type of Night
radRegular Text Regular
radCar Text Car
grpData Text Sales Data
lblNumCars Text Number of Cars:
txtNumCars Text (empty)
lblNumTickets Text Number of Tickets:
txtNumTickets Text (empty)
lblPopcorn Text Number of Popcorn:
txtPopcorn Text (empty)
lblCandy Text Number of Candy:
txtCandy Text (Empty)
grpTotal Text Total Sales
lblTotal Text (empty)
grpOperations Text Operations
btnCalculate Text Calculate
btnClear Text Clear
btnExit Text Exit
You are free to experiment with colors and form design as you see fit. However, your application must meet the listed requirements.
Once the total sales are calculated, the program will display a summary message with the following:
• type of night;
• total number of cars;
• total popcorn sales;
• total candy sales; and
• total sales amount.
Step 4: Implement the Event Handlers
Use the following as the design for your event handlers, referring to the flow chart for rules on input validation and processing. The final calculation SHOULD NOT be completed until all the input fields are validated.
Control Name Event Task
btnCalculate Click Get number of cars and validate
Process Night type
Process Ticket Data
Process Popcorn Sales Data
Process Candy Sales Data
Process Total Sales
Display output string
btnClear Click Clear all textboxes and output label
btnExit Click Close program (hint: use “Me.close”)
Step 5: Executing the Program
To execute your code, click Start and then start debugging. Check your output to ensure that you have space(s) where appropriate. If you need to fix anything, close your execution window and modify your code as necessary and rebuild.
Step 6: Deliverables
1. Capture a screen print of your output (do a PRINT SCREEN and paste into an MS Word document).
2. Copy your code and paste it into the same MS Word document that contains the screen print of your output.
3. Save the Word document as CIS170A_Lab03_LastName_FirstInitial.
4. Zip up the Word document along with a complete set of project files into a single document.
5. Place deliverables in the Dropbox.
END OF LAB
* You can also use 2CO option if you want to purchase through Credit Cards/Paypal but make sure you put the correct billing information otherwise you wont be able to receive any download link.
* Your paypal has to be pre-loaded in order to complete the purchase or otherwise please discuss it with us at firstname.lastname@example.org.
* As soon as the payment is received, download link of the solution will automatically be sent to the address used in selected payment method.
* Please check your junk mails as the download link email might go there and please be patient for the download link email. Sometimes, due to server congestion, you may receive download link with a delay.
* All the contents are compressed in one zip folder.
* In case if you get stuck at any point during the payment process, please immediately contact us at email@example.com and we will fix it with you.
* We try our best to reach back to you on immediate basis. However, please wait for atleast 8 hours for a response from our side. Afterall, we are humans.
* Comments/Feedbacks are truely welcomed and there might be some incentives for you for the next lab/quiz/assignment.
* In case of any query, please donot hesitate to contact us at firstname.lastname@example.org.
* MOST IMPORTANT Please use the tutorials as a guide and they need NOT to be used for any submission. Just take help from the material.
******************************************** Good Luck ***************************************************
Any personal information received will only be used to fill your order. We will not sell or redistribute your information to anyone.
We will try our best to resolve the issue and if still persists we can discuss for a refund in case its required.