Spokane Falls Community
CS223 - Introduction to Visual
Basic Winter Syllabus
Instructor: Paul Lecoq - Office 18-112A
Back to home page
By the end of this course you should
be able to create Visual Basic programs for a wide variety of applications
using forms, objects, functions, procedures, arrays, and disk files. You
will also be able to access a data base through Visual Basic.
BACKGROUND & DISCUSSION
Visual Basic has automated some of
the most sophisticated and difficult problems in writing programs: Specifically,
the user interface. Rather than long drawn out algorithms to collect and
validiate inputs, event driven objects do most of the work so you can concentrate
on creating very user-friendly applications.
||Assignments are due on the Monday of the week
in which they are noted here.
||Late assignments may
be docked up to 50%
||Warm and fuzzy week
introduction to VB
Use several controls
Be exposed to decisions
of chapter prog Exercises
0:Last Name First
Asgt 1: Assignment cover
work to class
get serious about VB
Variables, constants & calculations
Asgt 2. English
- Metric Temperature conversion program
due 12 April
work to class
Decisions and Conditions
Coding for events
Please read this
page on event driven programs
Assgt 3 Loan Payment Calculator
Asgt 4: Payroll Calculator see info below.
Due 19 April
|Menus, subs, functions, OOP
Asgt 5: Rental Form
Asgt 6: Perimeter
due 26 April
just a little of 8
Read the appendices
asgt 8: String Parser
Due 3 May
Note: This is out of order
structures - loops
and Midterm exam with take-home asgt
asgt 7 Simple data base program
due 10 May
Data Base connections
Asgt A-9 Test
due 17 May
Group leaders start asgt 10
what we have learned to real world problems.
||Really get serious about
most of our efforts into finishing our applications
Graphics, Adv. Stuff
Asgt 10 begins:
Final Project - Hospital multi-form project
|10- Group leaders present RQMTS
Mon, Tue only
If we have time
||Finish everything off
Everything turned in
Class project demonstration
Thursday, December 9, 2004
Since mastery of a programming language
means that you can create programs/applications in that language you will
be evaluated primarily on how well your programs work and how easily they
could be maintained through the projects/assignments you turn in. The exams
will sample the depth of your understanding of the material presented in
|Criteria for grading Exams:
|92 % - 100 % = A
||Correct/Actual Program Code = 50%
||One Test = 200 pts
|85 % - 91.9 % = B
||Documentation/Style = 25%
||Seven assignments = 500 pts
|75 % - 84.9% = C
||Test Plan = 25%
||Attendance & participation = 100 pts
|68 % - 74.9% = D
|| Late assignments may be docked up
|| You must turn in all assignments to receive a passing
|Below 68% = F
Attendance policy: I will take attendance about
once per week. Five absences is too many.
for Phase II and Phase II
The week the program is assigned you
will turn in a program specification for the assigned program.
The program must be handed in by the
due date as hard copy with the following:
- Assignment ID and
title exactly as shown in the syllabus
specification -- If this is different from the original, all changes
will be noted explicitly with reasons for the changes.
test plan -- How are you going to test the program to show that it
properly performs per the specification and the results of the test.
hard copy with annotating comments -- Complete program with source
text and screen images -- NOT "Form as Text"!
- Disk with program in its
own folder - This will be returned within one week
Each assignment will be formatted as follows:
'Assignment 2 A Exact title of assignment
Without these, I will return your program
Visual Basic Date
and you will have to resubmit properly
'Brief description of what the program does
You will hand in:
- A hard copy of the program code (with the above header)
- A hard copy of the program screen showing active data
- Proof that the program works - a test plan
Beginning with assignment 2:
- Annotate your program with sufficient comments
- Comment every decision
- each sub or function or method will include a descriptive comment
- Document as if you were turning over the program for someone else to
in the book has a complete case study demonstrating the program development
process from analyzing the problem to coding the final product. The specific
layout and formatting is up to you. The following items are expected in
your test plan:
each input (text box, button, slider, etc), a list of values to test all
Code Format: The source Code must have (Here
is an example In Word 97 Format):
if the acceptable range is from 7 to 25 inclusive then you will need a
value less than 7, a value between 7 and 25, a value greater than 25. In
this case it would be good to also use 7, 25, 0, and a negative value,
and a positive value between 0 and 7.
expected response/output for each input.
expected reports based upon the inputs given.
Module definition - The title and purpose of each module in the program
documentation - Sufficient documentation to make the structure of all
code very clear to someone other than the programmer. Especially the decisions.
conventions - All objects and variables will be named with meaningful
names. "Text17" is not a meaningful name! txtLastName is.
for printing - All printouts of source code should use the font "Courier
New" with a point size of 10. Print in landscape (11 inches wide by 8.5
inches tall) and not portrate (8.5 inches wide by 11 inches tall). the
Code should be be on the left side of the page and most of the comments
in your code should be on the right.
Assignment 1 Cover sheet
grade report form -
Create a program which you can use this quarter to produce a cover page for
all your assignments. The format should look something like this:
Visual Basic Project CS-223
Project # 1 Project
name Cover Sheet
Score: ______________ _______________
Write the program so that you can call it up and enter the important
information for each subsequent assignment. Then you can print the cover
sheet and attach it to the hard copy of your project.
Assignment 2 Temperature conversion
program with slider:
Part A --
Create a program with a slider control/scroll
bar which selects a temperature between - 40 and + 451 degrees Fahrenheit.
As the temperature is changed via
the scroll bar, display the Fahrenheit and equivalent Celsius temperature
in text boxes.
As the temperature changes, change
the background color of the form from blue (cold/Below freezing) to light
grey (between freezing and boiling) and Red (Boiling and above).
Extra credit: Make the
program convert both Fahrenheit to Celsius or Celsius to Fahrenheit
Part B -- Create a program similar to part A but which gives the user
several choices of conversions. The user should be able to convert in both
directions, english to metric and metric to English.
Include conversions for pounds/KG, Inches/meters, Miles/KM, & quarts/liters.
Loan Payment Calculator
- Create a program interface with the following input
Annual Percentage Interest rate (%)
Number of monthly payments
- Your program is to calculate and display the following:
One button "OK" initiates the calculation
Another button "Clear" empties all the data areas on the form to get ready for
A third button "Exit" causes the program to halt.
Your program must check the down payment to assure that it
is less than the sale price, the annual Percentage Interest rate to assure
that it is between 0 and 20%, and the number of payments to assure that it is
in the range of 1 to 46.
The equation for this calculation is
Loan Amount * Monthly Interest Rate
1-(1+ Monthly Interest Rate) ^ -number of payments
Assignment 4 ---- Salary calculator
Set up a screen that would be appropriate for a timekeeping clerk
to enter the working hours for an employee.
Your program will provide a list box with the valid employee numbers and
names of the employees.
The program allows the clerk to click on one of the
list items to transfer that employee's name and number to the form. the
remaining information will be typed into the form by the clerk. Include at
least the following information:
Number of hours worked each day Monday
Any hours that should be counted as overtime but wouldn't normally be calculated
as overtime for the week
Hourly rate of pay
% deduction for taxes
Your program should calculate hours worked and amount
paid as follows
0-8 hours per day straight time over 8 hours in a
Saturday and Sunday hours are overtime
Under special circumstances as determined by the clerk, some
hours that might normally be paid as
straight time may be paid as
Calculate the gross pay at the hourly rate for straight time and
time and a half for overtime.
Deduct for taxes and a standard 1.5% for insurance
Print the results in the
form of a check stub. (On the screen is fine)
Assignment 5 --- Yacht rental
agency Rental form
Page 327, problem 7.3
Assignment 6 ---
Area Calculation program.
Write a program that will give
the user the choice of circle, square, rectangle, and triangle. When the
user chooses one of these, allow the entry of the appropriate size parameters
(lengths) then calculate and display the area contained in the shape.
Extra Credit: Draw the shapes to scale.
Assignment 7 -- Simple
data base program
Create a simple data base with one table.
Use Access as needed
A sample table will be provided
Create a program which
accesses the data base and displays it in a data grid.
Display key fields in
Write a program that will accept a line of words (perhaps a sentence) and
separates each of the words into an array when the user clicks on the button
When the user clicks on the button <Display> the words will be transferred from
the array to a list box.
- Sentence delimiters: . ? !
< > space ,.;:'?" !
Assignment 9 -- Test
administrator -- Define details in class Program Part 1:
Do this program from a data base
Create a program to give and grade
quizzes (Students are to pair up with a fellow student for this assignment).
-- Create and utilize a User Defined
Data Type (UDT) to store the question, four answers as strings, and which
is the correct answer.
-- There must be at least 15 Questions.
-- The questions must be given in
a random order without repeating a question.
-- Give score and grade to students
once the quiz is done.
-- You may pick the topic of the quiz.
Assignment 10 Final Project
- Employee timekeeping Information System: (or
other assignment at the discretion of the instructor)
Assignment 7 Final Project
- Employee Information System:
Note: The instructor will consider
alternative projects if one or more students would like to suggest one.
This program will operate as two component parts which work together.
We prefer that you create these programs in groups of two or three
students. This probram must use an ADO data base for storing and
program will allow administrators to create a database table of employees which
includes their normal shift hours, rate of pay, names and social security
number. A separate "in_out" table of "punch-ins" and
"punch-outs" is maintained by the user program as employees come to
and leave work. This table also includes fields for Hrs Worked and for YTD
The administrative program will go through the "in_out"
table and for each employee, posts the hours worked this week and adds to YTD
hours worked. It will also generate a hard copy report of each employee's
displays a list of employees when running. Any time an employee clicks on
his name, the User program will post the enter/leave entry with the current time
to the "in_out" table.
The presentation of the list of
employees will include a place to click for beginning a shift (punch in) or
leaving a shift (punch out).
Milestone 1 - Diagram of the data
structure used in the program and in the file(s).
Milestone 2 - The user interfaces
for both programs (their look and operation).
Milestone 3 - A preliminary test plan
and Pseudo-Code for each of the programs
Milestone 4 - Present the program
to the class and explain how it works.
FINAL PRODUCTS :
-- Screen Prints.
-- Source Code.
-- Pseudo Code.
-- Test Plan.
-- Results of testing against plan.
-- List of who worked on what part
of the program.
-- All of the above on a Floppy Disk
(if there is not enough room on one floppy disk, put the program on one
floppy and everything else on a second floppy disk)
-- A short, one page (about 500 words)
from each person on what they learned from this assignment.
Back to home page