assignment objectives to practice or use the following: 1.controls: - buttons, labels, textbox for...

15
ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1. CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes , and a panel . 2. EVENTS: - Click, MouseDown, and MouseUp 3. To learn how to use internal documentation 4. To learn how to place an icon into a button 5. To learn how to set properties in the Property Window. 6. To learn how to set properties in the code. 7. To learn how to use the Visible property to hide and show a panel. 8. To learn how to exit a program using Me.Close(). “Close” is a method (a behavior). 9. To learn how to accumulate using a counter variable. 10. To learn how to DIMension a variable. 11. Learn to use a panel to hide controls under it. 12. To learn how to submit a program.

Upload: esmond-stanley

Post on 19-Jan-2018

214 views

Category:

Documents


0 download

DESCRIPTION

AN EXAMPLE OF HOW INTERNAL DOCUMENTATION MUST BE DONE. Fig INTERNAL DOCUMENTATION EXAMPLE PROGRAM DOCUMATION The program must have documentation at its beginning. You MUST use this form for your programs. SUB PROCEDURE DOCUMENTATION Each procedure must have documentation at its beginning. You MUST use this form for your programs. The heading must be all caps and contain no more than four words.

TRANSCRIPT

Page 1: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

ASSIGNMENT OBJECTIVESTO PRACTICE OR USE THE FOLLOWING:1. CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel.2. EVENTS:

- Click, MouseDown, and MouseUp

3. To learn how to use internal documentation

4. To learn how to place an icon into a button

5. To learn how to set properties in the Property Window.

6. To learn how to set properties in the code.

7. To learn how to use the Visible property to hide and show a panel.

8. To learn how to exit a program using Me.Close(). “Close” is a method(a behavior).

9. To learn how to accumulate using a counter variable.

10. To learn how to DIMension a variable.

11. Learn to use a panel to hide controls under it.

12. To learn how to submit a program.

Page 2: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

GETTING HELP:You may ask another student for help, but you must not copy their code. Failure of the course will result for the person giving code and the person receiving code.

I can get limited help from other students. For additional help, I need to see Dr. Scanlan, or possibly the tutoring center.

Page 3: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

AN EXAMPLE OF HOW INTERNAL DOCUMENTATION MUST BE DONE.Fig 2-330

INTERNAL DOCUMENTATION EXAMPLE

PROGRAM DOCUMATION• The program must have documentation at its beginning. You MUST use this form for your programs.

SUB PROCEDURE DOCUMENTATION• Each procedure must have documentation at its

beginning. You MUST use this form for your programs. The heading must be all caps and contain no more than four words.

Page 4: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Fig 2-350

SUB PROCEDURE DOCUMENTATION• Each procedure must have documentation at its beginning. You MUST Use this

form for your programs. The heading must be all caps and contain no more than four words.

AN EXAMPLE OF HOW INTERNAL DOCUMENTATION MUST BE DONE.

INTERNAL DOCUMENTATION EXAMPLE

Page 5: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Due Dates: Oct 9, 2014

START ASAP!20 POINTS: Purpose:The manager of a Blockbuster Video store has asked you to modify Program-01 so that he can track which categories are selected most often.In addition, you are to modify Part01 so that the counters are not visible to customers; that is, they are only visible to employees after the employees have entered a password. (Use PASSWORD as the password.) The employee must be able to reset the counters back to zero and show an empty label as below, and be able to shut the program off by pressing an EXIT button.

Requirements for Part-02:1. The GUI must look REASONABLY close to the one below.2. The program MUST behave as indicated in the following slides. Each slide will show what happens after certain buttons are pressed. 3. PAY CLOSE ATTENTION TO EACH SLIDE.(Continued on the next slide.)

Programming Assignment 02

Necessary prerequisites1. Chapters 1, 2, 3, 42. Notes: 010, 020, 030, 0403. How to accumulate4. Visible Property5. GroupBoxes7. Class Lectures.

Button Location Aisle Color

Comedy Aisle 1 BrownDrama Aisle 2 BlueAction Aisle 3 OrangeSci-Fi Aisle 4 GreenHorror Aisle 5 RedNew Releases Aisle 6 Yellow

Store’s layout

Page 6: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:4. Write the code and set the design-time properties so that the GUI looks as below immediately after the program is run.

Programming Assignment 02

THIS GUI IS SEEN IMMEDIATELY AFTER THE PROGRAM IS RUN

PRESSING DOWN ON THIS START BUTTON WILL PRODUCE THE GUI ON THE NEXT SLIDE.

Page 7: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:5. Write the code and set the design-time properties so that the GUI looks as below while the START button is press down.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN AFTER THE START BUTTON HAS BEEN PRESSED DOWN.

NOTE: THE PROPERTIES OF THE START BUTTON ARE THE SAME AS THE SELECTION BUTTONS IN PART01.

Page 8: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:6. Write the code and set the design-time properties so that the GUI looks as below immediately after the START button is released.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN AFTER THE START BUTTON IS RELEASED.

PRESSING DOWN ON THIS ACTION BUTTON WILL PRODUCE THE GUI ON THE NEXT SLIDE.

NOTE: ALL SIX SELECTION BUTTONS BEHAVE AS THEY DID IN PART01 WHEN THEY ARE PRESSED AND RELEASED, AND THE AISLE LOCATIONS AND COLORS REMAIN THE SAME AS THEY DID IN PART01.

Page 9: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:7. Write the code and set the design-time properties so that the GUI looks as below while the Action button is pressed down.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN WHILE THE ACTION BUTTON IS PRESSED DOWN.

NOTE: ALL SIX SELECTION BUTTONS BEHAVE AS THEY DID IN PART01 WHEN THEY ARE PRESSED AND RELEASED, AND THE AISLE LOCATIONS AND COLORS REMAIN THE SAME AS THEY DID IN PART01.

Page 10: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:8. Write the code and set the design-time properties so that the GUI looks as below immediately after the Action button is released.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN WHEN THE ACTION BUTTON IS RELEASED.

NOTE: ALL SIX SELECTION BUTTONS BEHAVE AS THEY DID IN PART01 WHEN THEY ARE PRESSED AND RELEASED, AND THE AISLE LOCATIONS AND COLORS REMAIN THE SAME AS THEY DID IN PART01.

Page 11: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:9. Write the code and set the design-time properties so that the GUI looks as below immediately after the password is typed into the textbox.10. The textbox must be set to turn all letters to lower case and to display asterisks for each character entered.11. The password must be “password”. 12. The program does not advance to the next slide when the Display Counters Button is pressed, unless the password is correct. Use an IF-

THEN-ENDIF statement to check for a correct password.

Programming Assignment 02-PART02

CLICKING THE Display Counters BUTTON WILL PRODUCE THE GUI ON THE NEXT SLIDE. USE A

CLIC

K EVEN

T FOR

THIS B

UTTO

N.

THIS IS WHAT IS SEEN WHEN A PASSWORD IS ENTERED BY AN EMPLOYEE.

Page 12: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:13. Write the code and set the design-time properties so that the GUI looks as below immediately after the Display Counters button is clicked.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN AFTER THE Display Counters BUTTON IS CLICKED.

CLICKING THE Reset BUTTON WILL PRODUCE THE NEXT SLIDE

Assume that New Releases had been pressed 5 times and the others 1 time each.

Page 13: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Requirements for Part-02:14. Write the code and set the design-time properties so that the GUI looks as below immediately after the Reset button is clicked.15. Your program must have internal documentation. See previous slides for an example.

Programming Assignment 02-PART02

THIS IS WHAT IS SEEN AFTER THE Reset BUTTON IS CLICKED.

WHAT THE Reset BUTTON DOES:1. It Resets the program to its STARTing position.2. It Resets ALL six of the counters to 0.3. The program has been reset and it will now behave as

it did starting from slide 6.

Page 14: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Form-A Form-A

Programming Assignment 02

STUDENT FILLS IN THESE BLANKS:

LAST NAME (PRINT):_______________________________

FIRST NAME (PRINT):________________________

PROGRAM (Circle) 1 2 3 4 5 6 7 8 9

DATE DUE:_____________________

DATE SUBMITTED:___________________

GRADER FILLS IN THESE BLANKS:DESCRIPTION POINTS POSSIBLE POINTS EARNEDCorrect internal documentation: 0 OR 2 _____________Reasonably correct GUI: 0 OR 1 _____________Program runs correctly: 0 OR 13 _____________Proper style for object names: 0 OR 2 _____________Proper style for variable names 0 OR 2 _____________Failure to submit program correctly (See Form-B) 0 OR -2 _____________Late penalty (10 points off for each class day late.): -10 OR -20 _____________

TOTAL POINTS OUT OF A POSSIBLE 20: _____________

If your program does not run correctly, get help and hand it in the next class day. Five points deducted for being late is better than twenty points deducted for a faulty program.

Page 15: ASSIGNMENT OBJECTIVES TO PRACTICE OR USE THE FOLLOWING: 1.CONTROLS: - buttons, labels, textbox for password, picture boxes, groupboxes, and a panel. 2

Form-B Form-b

Programming Assignment 02

STUDENT FILLS IN THESE BLANKS:

LAST NAME (PRINT):_______________________________

FIRST NAME (PRINT):________________________

PROGRAM (Circle) 1 2 3 4 5 6 7 8DATE DUE:_________________DATE SUBMITTED:__________________

PLACE A CHECK NEXT TO THE FOLLOWING:

1. ____ Saved the Program on a CD using the following directory andsub-directory: Drive Letter:/Your Name/Program02

2. ____ Printed your full name and program number on the CD using a

permanent black marker.3. ____ Submitted the CD in an envelope not much larger than the CD.4. ____ Placed the CD in the envelope.5. ____ Place Form-A in the envelope. Fold if necessary.6. ____ Cut out this form along dotted edges and tape it to the envelope.

(You may also use a DVD-R)

CUT OUT THIS FORM ALONG THE DOTTED EDGES AND TAPE IT TO THE ENVELOPE.