DIS 312 Fall 2003 Homework Assignment

First Name: Last Name: PIN:
Semester: Class:
Section: Assignment:
 


500 points

DIS 312 Homework Chapter 5

Selection Structures


Exercises


Exercise 5.4, page 187- Modify btnGuessMe_Click in Example 5.1 so that the user still enters a guess and clicks the button each time, but now when the user guesses correctly, it displays its congratulations, displays the number of guesses taken , and ends execution of the program (using the End statement). When the user's guess is incorrect, the event procedure should merely display condolences.

(50) Take your executable file from the solution folder and post it on your studentweb site, with a link to this file on your homework syllabus.
The executable file has an extension of .exe and is found in the /bin subfolder of the solution folder. When viewed through Windows Explorer or My Computer it will have a file type of 'application'.

(25) Paste below a screen shot of the congratulations Message box.

 

(25) Paste below a screen shot of the condolences Message box.

 

(25) Exercise 5.8, page 190- Place below the "statementblock" code you need to complete the btnVerifyAscending_Click() event procedure.

Note: You must be very careful typing in the last 2 lines of code for this problem. Make sure to enter spaces, or you will receive an error message.

Sequence = "Sequence " & X & "'" & Y & ", " & Z
Msgbox Sequence & "is " & BlankOrNot & " in ascending order"


(50) Exercise 5.12, page 196- Write the btn click event procedure. Modified 6/13/03. Eliminated .exe file

Modified 6/13/03. Do not paste screen shot


(50) Exercise 5.18, page 210- Modify Example 5.8 so that it does not display the message "ARG has 0 days" when the user enters an invalid month abbreviation, (ARG in this example).

Paste modified code here:

 

(25) Take your executable file from the solution folder and post it on your studentweb site, with a link to this file on your homework syllabus.
The executable file has an extension of .exe and is found in the /bin subfolder of the solution folder. When viewed through Windows Explorer or My Computer it will have a file type of 'application'.


End-of-Chapter Problems

(50) Problem 6, page 223- Create the required Select Case statements:


Programming Problems

Be prepared to demonstrate your solution to the instructor during class.

Sample Solution: Prob2.exe    Note: if you have trouble running this file, there is another copy at \\store\classes\000195\readonly\ChapterExamples\Chapt05\Prob2.exe

Programming Problem 2, page 225-Checklist:

1. (25) Form with required controls. Paste screen shot of form below:

 

2. (25) What code controls showing and hiding the options? (lox/cream cheese, spinach/chef, cola/cream soda) Explain...

3. (25) How do you clear the price when a main selection is "deselected"? Explain...

4. (25) How do you clear the options when a main selection is "deselected" and then selected again? Explain...

5. (25) How do you set the Bagel options to be cumulative, while the Salad options are mutually exclusive (you can only choose one)? Explain...

6. (75) Make a copy of your executable file from the solution folder and post it on your studentweb site, with a link to this file on your homework syllabus.
The executable file has an extension of .exe and is found in the /bin subfolder of the solution folder. When viewed through Windows Explorer or My Computer it will have a file type of 'application'.


Important: Assignments can have two parts.
1. Form Part
The form part will have dark blue text. The form part is best answered by placing your answer in the form TextArea Box Properties 'Initial Value' field as shown below from FrontPage2002. Do not delete any of the TextArea boxes! This method will keep your answer in your .html file when you publish / ftp your homework to your studentwebsite. Never change the Name field (q1, q2...)!

2. Normal Html Part
The normal html sections will have black text. You can type your answers into the table provided using FrontPage2002.
When you have completed this HW assignment publish (ftp) it to your studentwebs site.
Make sure to activate the hyperlink for this assignment on your HW template file.
Use a web browser to make sure you can view the completed assignment with your answers and make sure that any graphics files are visible and correctly linked.
Correct any problems that you find.

When you are satisfied that your assignment has been done correctly fill in the form fields for First Name, Last Name, PIN, Semester, Class, Section and Assignment. Remember to choose a PIN number at the start of the semester. You will use this PIN number to verify that your homework was indeed submitted.

These fields have a blue background.

Once this is done, press the submit button. This sends a copy of your assignment answers to the professor. If all goes well, you will see a confirmation page. At this point your homework has been submitted. Before this, you have not completed your assignment.
Caution: Pressing the Submit button more than once sends additional copies of your answers to the instructor and records the time of submission. The assignments are due by 11:59:59pm on the day assigned. If you press the submit button after the assignment is due, your assignment is late and points will be deducted.