PRG 240 - Class #4 Lecture
Take an open-book quiz where you have to create a MDI project
with a parent form and two child forms. The parent form must contain a File
menu with View Form1 and View Form2 commands that allow the user to view each
form. Each form should have an Exit command button that allows the user to close
that form. The File menu should also have an Exit command that properly allows
the project to exit. Copy the folder that contains this project onto a labelled,
blank floppy disk and submit to the instructor.
Join the class mailing list. The
following people have already subscribed - s_k61, Jennifer, & rach.
Finish reviewing the online Ch. 2 Notes.
If necessary, discuss and demonstrate the image box, toolbar, status bar, listview,
treeview, and tabbed dialog box controls. Any questions with the Add methods
for the TreeView Nodes collection, the ListView Items collection and the ListView
Item's Subitems collection?
Review MS Access. Open the AVB.mdb Access database that is supplied on the
Student CD-ROM. Identify the primary key in each table. Create a database with
2 or more tables from scratch to familiarize yourself with Access.
Discuss Ch. 3.
- Have a passing familiarity with OLE DB & ADO. (p. 94)
- Understand database terms such as tables, records, fields, & key field
(primary key). (p. 95)
- Do not worry about using the Visual Data Manager in this course. We will
use MS Access to create our database files. (p. 96)
- Use the Project/Components... menu command to add the Microsoft ADO Data
Control 6.0 component to a project. This allows you to use ADO data controls.
- Data-bound controls display data from the field of a table that is linked
via an ADO data control. You typically place one ADO data control on each
form to link that form to an Access table.(p. 97)
- You must use the Connection String property of an ADO data control to indicate
the path & filename to the Access file that contains the table you wish
to use. The RecordSource property is set to the table's name and the CommandType
property is adCmdTable. (pp. 100-101)
- Once you have set up the ADO data control to connect to the desired Access
table, you need to set the DataSource property of a given data bound control
(e.g. label, text box) to the ADO data control on the form. (p. 102)
- The DataField property for this bound control must be set to the desired
field of the table (DataSource). (p. 103)
- Execute the example from pp. 103-106 of the textbook.
- Obtain the Ch03SBS1 project folder from the Student CD-ROM. (You may
have to change them from read-only.)
- Make any necessary modifications to the Connection string for the adoPatient
ADO data control so that you can execute the project.
- Examine the code for this project.
- What is the name of the ADO data control?
- What data-bound controls are being used?
- Do Feedback 3.1 on p. 106 as a class.
Ch. 2 VB Auto Center debugging
- Any general questions about VB Auto Center which is due next week?
- Spend the rest of class time working on this programming assignment which
is due next week.
- Finish the the Ch. 2 VB Auto Center case study on p. 92 by
Mar 12. This project will be due on a
labelled floppy disk. The code for each form should also be printed out and
stapled with the parent form on top. You will have to create your own fictitious
data for the ListView on the Auto Inventory form. Add a popup (shortcut) menu
of some kind (it can be simple).
- If you haven't already, read Ch. 3 pages 94-132.
- If you haven't already, take the time to follow the textbook's "Step
by Step" tutorials on pages 103+, 108+, 111+, 114+, and 121+ even though
these examples can already be found on your Student CD-ROM. Note that you
may need to interchange Step 6 and Step 5 on p. 104 as well as Steps 4 &
5 in the middle of p. 122.
- Read Ch. 3 pages 132-154. Also, review and execute the Ch. 3 Advanced Vision
and Beyond project (can be found on the Student CD-ROM).
Copyright © 2001 Curtis Minich. All Rights Reserved.