Comp 201 – Summer 2007 - Assignment # 1
Due: May 11, 2007
The purpose of this assignment is to help you become familiar with the Visual Basic 6 Development Environment, which you will be using for programming during this course.
You should carry out the following elementary steps. If you are not sure of how to perform step # 2, asking other students near you in the lab or the lab monitor could be of a great assist.
1. Obtain a computer account for COMP 201 from the IITS booth at H-925, or through your personal account at www.myConcordia.ca.
2. Go to the PC labs indicated on your account card and choose a computer. Check that both the computer and the monitor are switched on. Logon to your account and start Visual Basic 6.
In this assignment you are required to build a three-number calculator. The final Graphical User Interface (GUI) for your calculator should look as similar as possible to the following.
You program should behave as follows: (Assume that the user will always enter three valid integer values in Value1, Value 2 and Value3 textboxes.
1. When the user clicks on the Add button, the summation of Value1, Value2 and Value3 should appear on the Result textbox.
2. When the user clicks on the Subtract button, the subtraction of Value1 + Value2 and Value3 (Value1 + Value2 – Value3) should appear on the Result textbox.
3. When the user clicks on the Multiply button, the multiplication of Value1, Value2 and Value3 should appear on the Result textbox. An overflow error as a result of large values can be ignored.
4. When the user clicks on the Divide button, the division of Value1 by the summation of Value2 and Value 3 (Value1 / (Value2 + Value3)) should appear on the Result textbox.
5. When the user clicks on the Expo button, the exponent of (Value1 + Value3) to the power of Value2; that is ((Value1 + Value3)Value2), should appear on the Result textbox.
6. When the user clicks on the Author Info Button, a message should appear on the form indicating the name and the ID of the author of this program (you). Consequent clicks on the Author Info button should NOT result in more than one message indicating the author name being printed on the form.
7. When the user clicks on the Exit button, your program should terminate.
You must submit the following: (see the course outline for the submission rules)
I. A hardcopy of your source code only.
II. A softcopy of your entire program (project, forms, code, etc.) on a floppy diskette or CD .
Comp 201 – Summer 2007 – Assignment # 1 – Page 1 of 1