COP3175, Homework 5
Due June 16 at the start of class
Upload a ZIP file of your project and hand in a printout of the form file.
This program deals with accessing the Biblio database. To make sure that
your program will run on my system, please copy the
Biblio.mdb file to your C:\ directory or to your
U:\ directory (you may create a shortcut instead of copying the file). You
may copy your own Biblio.mdb, or download the one that I have.
-
Part I
-
Display a combo box that is a dropdown list. The combo box will contain the
names of the tables in the Biblio.mdb. Enter these names in the List property
in the properties list for the combo box in the form editor.
-
When the user clicks on a table name, fill a list box with the names of the
fields in the table. Map the event for when the combo changes and set the
values in the list box at run time. Make the items in the list box appear
as check box items. Enable Multiple Selections in the list box. Make sure
that any previous values in the list box have been removed before adding
new elements.
-
Have a button labeled "Execute Query". When clicked, it will generate a query
on the table name in the combo box that will display only the fields that
are selected in the list box. Display the results in a DataGrid. Do not allow
updates.
-
If no table has been selected then display an error message.
-
If no fields have been selected then display an error message.
-
Part II
-
Display a data combo box that will list all the names of the publishers in
the Publishers table of Biblio.mdb.
-
When the user selects a publisher from the drop down list, display all the
books for that publisher, and the year each was published, in a data grid.
Do no allow updates in the data grid.
-
Calculate the minimum year and the maximum year of all the books displayed
for that publisher. Show the results in a label. If the year is not valid
then ignore it. To be valid, a year must be in the range 1900-2005.
-
Display a frequency total of all the years for that publisher. Only display
positive totals. Frequency totals are discussed in Chapter 7.
-
Notes
-
Do not use global variables, but you may use global constants.
-
Do not have "magic numbers" like 1900 and 2004 in your program, use global
constants.
-
Use functions and subs.
-
No function, sub, or event procedure may exceed 25 lines.