Access New Book

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 170

University Technology Training Center

Access 2007:
Basic Database Development

UNIVERSITY TECHNOLOGY TRAINING CENTER

Basic Database Development

Access 2007:

2009 Regents of the University of Minnesota University Technology Training Center All Rights Reserved uttc.umn.edu

The University of Minnesota is committed to the policy that all persons shall have equal access to its programs, facilities, and employment without regard to race, color, creed, religion, national origin, sex, age, marital status, disability, public assistance status, veteran status, or sexual orientation.

This publication/material can be made available in alternative formats for people with disabilities. Direct requests to: University Technology Training Center 190 Shepherd Labs 100 Union Street Southeast Minneapolis, MN 55455 612.625.1300 uttc@umn.edu

07.08.2009

Table of Contents
LESSON 1 INTRODUCTION TO DATABASES
Database Design Vocabulary Relationships Design Process

1 1
1 2 4

LESSON 4 CREATING RELATIONSHIPS


Print the design Removing Tables from the Diagram Deleting or Editing Relationships

33 33
37 38 38

LESSON 5 LESSON 2 BUILDING A DATABASE IN ACCESS


Create an Access Database Set Access Options Creating Tables Exercise 1: Creating Tables Creating a Join Table

39 39
40

7 7
7 10 14 20 21

MODIFYING TABLES AND RELATIONSHIPS


Adding the New Foreign Key Field

LESSON 6 CREATING INTERFACES TO INTERACT WITH DATA


Using Forms vs. Tables for data entry

43 43
43 44 50 54 62 69 72 73 77

LESSON 3

23

S E T T I N G F I E L D P R O P E R T I E S 23
Resizing text fields Input Masks Default values Format number fields Exercise 2: Setting field properties 24 25 28 30 32

Creating the Member Status type Entry Form Exercise 3: Creating Entry Forms Using Multiple Items Form Option Handling One-to-Many Relationships with Subforms Exercise 5: Creating a Subform using Autoform Linking the Main form and Sub Form Navigating Records and Entering Test Data Creating Forms using the wizard Exercise 6: Creating the CD entry form using the Wizard

UNIVERSITY TECHNOLOGY TRAINING CENTER

Adding to combo box lists on the fly Finding a Record on a Form Using a Combo Box to Find Records on the Form Creating the Member CD Form and Subform in Design View Date picker

81 84 87 91 99

LESSON 10 FINAL TOUCHES


Menu Database Maintenance and Backups

137 137
137 143

APPENDIX A LESSON 7 EDITING A FORM


Modifying a Form

147 147

101 101
101

USING THE LABEL REPORT WIZARD

APPENDIX B LESSON 8 QUERIES


Creating a Query using the Query Wizard

151

105 105
105

CREATING A QUERY USING AGGREGATE FUNCTIONS 151

APPENDIX C

155

Exercise 7: Creating a Query Using the Wizard 112 Adding Criteria to a Query Creating a Query in Design View Exercise 8: Creating a Query in Design View End of Exercise 114 116 119 120

E X P O R T I N G Q U E R Y R E S U L T S 155

APPENDIX D CREATING A MEMBER ADDRESS REPORT USING THE WIZARD

159

159

LESSON 9 REPORTS
Creating a Report Using the Auto Report option

121 121
121

APPENDIX E EXPORTING A REPORT

163 163

Exercise 9: Creating a Report Using Auto Report 125 Creating a Report Using the Wizard Exercise 10: Creating a Report Using the Wizard 126 131

UNIVERSITY TECHNOLOGY TRAINING CENTER

ii

1
Lesson
Lesson 1

Introduction to Databases
Database Design Vocabulary
Database

Field: One piece of information you want to track in your database

o Examples: Name or Birth Date or CD Title


Record:

A group of fields containing data about one particular person, event, item, etc. o Examples: CD Title and Artist and Genre and Release Year

Table: A group of records

o Examples:
TITLE The Best of Van Morrison Positive Friction Natural Sketches of Spain Kind of Blue Man of Constant Sorrow Sketches of Spain Kind of Blue Man of Constant Sorrow A Day Without Rain In Pieces American Idiot GENRE Rock Brazilian Jazz Jazz Bluegrass Jazz Jazz Bluegrass New Age Country Pop PERFORMER Van Morrison Celso Fonseca Miles Davis Miles Davis Rice, Rice, Hillman and Pedersen Ralph Stanley Miles Davis Miles Davis Ralph Stanley Del McCoury Enya Garth Brooks Green Day RELEASE DATE OWNER 1990 Amy Jones 2000 Amy Jones 2003 Amy Jones 1991 Amy Jones 1991 Amy Jones 1999 Amy Jones 2001 Amy Jones 1991 Andy Jackson 1991 Andy Jackson 2001 Andy Jackson 2002 Andy Jackson 2004 John Smith 2002 John Smith 2004 John Smith

Americana Donna the Buffalo

Rice, Rice, Hillman and Pedersen Bluegrass

I Wonder Where You Are Tonight Bluegrass

University Technology Training Center

LESSON 1: INTRODUCTION

TO

DATABASES

Example of a table in a flat/Excel file

Example of a table in Access

Best Practice

When you expect multiple values or repeating data in a table, you should consider splitting the table into two or more related tables. For example, in the flat/Excel file shown above, Miles Davis is listed several times, as are some of the Genres and Owners.

Relationships

Relationship diagram showing the relationships between various tables

University Technology Training Center

Types of Relationships

One-to-Many: The most common type. For every record in Table A,

there are multiple records in Table B o Example: One Member may have many Addresses (work, home, cabin, etc.)
Many-to-Many:

For every record in Table A, there are multiple records in Table B, and vice versa. In this case, a third tablecalled a Join Tableneeds to be created, which will contain only unique values. o Example: One Member may have many CDs, and the same CD may be owned by many Members
Best Practice

The Join Table name should be a combination of the two many-tomany tables (e.g., tblMemberCD). The Primary Key can be the Join Table name or the first initial of each table name followed by ID (e.g., MemberCDID).
One-to-One: The rarest type, it is used for security and organization

(i.e., avoiding empty fields that only apply to some records in the table)
Primary Key: Auto-numbered, unique ID for internal tracking and

for matching records between related tables


Foreign Key: A number-type field in a related table pointing back to

the Primary Key in another table

University Technology Training Center

LESSON 1: INTRODUCTION

TO

DATABASES

Best Practice

The Primary Key should be the table name plus ID (e.g., MemberID) and should be the same name in the table where it is used as a Foreign Key. (There are exceptions. In this course, the Foreign Keys LoanedToID and MemberID in tblMemberCD table both go back to the Primary Key MemberID in tblMember.) The Primary Key should always be the first field in each table, followed by any foreign key(s). Primary Keys should never be actual datanot even something unique like a Social Security number or Student ID. These values are obtained from an outside source and, while seemingly unique and reliable, could produce data entry errors.

Design Process
These preliminary steps are done on paper.

Statement of Purpose

Example: CD Club between friends: Database needs to catalog CDs

owned by each member and track the loaning of CDs between members. Classify all CDs by Genre, and list performer, year released, and value for each CD. Provide reports, such as member and CD listings.
Best Practices

Use Prefixes in form or object names to denote different object types (e.g., tbl for tables). Avoid using spaces or special characters in object and field names. For single, repeating values requiring consistent data entry and searching, use a Lookup Table or Value List.

University Technology Training Center

Value List: Works well for single, static, short lists of information

that is restricted to a list (e.g., Address Type). It is not easily updatable.


Lookup Table: Better for longer lists or those with multiple fields. It

is easier to add additional values at a later date. You can choose a level of restriction (e.g., Genre).

Determine Fields
Best Practice

Avoid multiple yes/no fields or fields that will be consistently left empty. Consider breaking out into a separate table or creating a Lookup Table of values to choose from. Keep items such as names (first name and last name) in separate fields. It is far easier to join those fields when needed than it is to separate a first name, last name, suffix, etc., to use in a mail merge or similar function. This also keeps them consistently in the same place. If you only have one field, you have little or no control over the order of entry. Consider an active/inactive status field instead of deleting records and losing history (such as Member Status).

University Technology Training Center

LESSON 1: INTRODUCTION

TO

DATABASES

Define Relationships

Refine and Test


Now is the time to review your design before you start creating your Access database. It is harder to make changes once you have data in the tables. Access is a database management system that also includes forms, queries, reports, etc. for ease of interacting with your data and extracting data from tables. Many other database systems (e.g., Microsoft SQL) require an interface be created in another program.
Forms: Queries: Reports:

Used for viewing, adding, and updating data Used to ask Access to return a selected portion of your data Used to format the data for printing

University Technology Training Center

2
Lesson
Lesson 2

Building a Database in Access


Create an Access Database
The first step to creating an Access database is to create and name the database file that will store all of the tables, forms, etc. The file will be given a *.accdb extension automatically. Anytime you open a database, an .laccdb file is created. The .laccdb file is used to store computer/user names and to control record-locking in shared databases. The .laccdb file always has the same name as the opened database and is located in the same folder. Whenever the last user closes the database, the .laccdb file is deleted.
1. Open Access

Start Programs Microsoft Office Microsoft Office Access 2007

University Technology Training Center

LESSON 2: BUILDING A DATABASE

IN

ACCESS

2. Create a new database

Click on Blank Database in the upper left corner

The window pane on the right hand side will change to:

3. Type in the name you want to give the database (in our case:

CDClub ). The .accdb extension will be added automatically for you.

University Technology Training Center

4. Choose where you want to save the database by clicking on the

browse folder icon.

Browse to and select your Desktop Access 2007 Basics folder

5. Then click Create. Access 2007s new interface will open initially to a new

table in datasheet view.

Before proceeding we need to view the Security Warning :

6. Click on Options

University Technology Training Center

LESSON 2: BUILDING A DATABASE

IN

ACCESS

7. Choose Help protect me from unknown content. This will turn off

Macros that could potentially do harm to your database or computer.


8. Click OK

Set Access Options


The Access 2007 interface
The interface for 2007 has changed significantly. Access is using the same ribbon menu system similar to other Office 2007 applications such as Word or Excel. Access 2007 gives us an initial table to work with in datasheet view. Before we start creating tables, there are a few settings to consider changing.

10

University Technology Training Center

1. Select the Office button in the upper left corner

2. Then select Access Options on the bottom right corner

University Technology Training Center

11

LESSON 2: BUILDING A DATABASE

IN

ACCESS

3. Select Object Designers from the left hand pane

Access 2007 has the default for text fields set at 255 instead of the old default of 50. That is much larger than needed for most fields and would eat up too much space. We will set this to a more reasonable 35 .

12

University Technology Training Center

Access has a new view called Layout view, its a cross between design view and form view. It lets you make changes to the design while seeing data in the fields at the same time. We will not be using this view in class and because it can be confusing to know what view you are in, we will disable it during class. That option is on the Current Database tab (these options only apply to the database you are currently editing.)

4. Uncheck Enable Layout View for this Database

5. After the changes have been made click OK

University Technology Training Center

13

LESSON 2: BUILDING A DATABASE

IN

ACCESS

Creating Tables
The first step is to create all the tables we will need in our database. Access gives us an initial table to work with in datasheet view. It includes a primary key simply called ID. You want to give the primary key a more meaningful name so it is readily apparent which table that ID belongs to. We will follow our best practice of naming the primary key as the table name followed by ID (with no spaces in the field name) Before we do that we are going to switch to design view. (We will do all of our design work with our tables in design view).
1. Click the View toggle button on the far left side of the ribbon.

Important Note!

For all objects we work with in this class, we will be switching back and forth between Design View of the object and the end user view or result (Data Sheet, Form, query results, or report results). The method of changing the view is identical.
2. Access will ask you to save the table first. Type in the table name

(tblMember will be the first table we create)

3. Click OK

14

University Technology Training Center

On the left hand side is the Navigation pane (formerly Object Browser) that will show all of the tables, forms, queries and reports in the current database.

On the right hand pane is the design view of the tblMember

The top section of the table Design View screen has three columns for entry of Field Name, Data Type, and Description.

Field Name:
Keep it short but meaningful No spaces or special characters Primary Key should be the table name plus ID (i.e., if the table is called tblAddress, the Primary Key should be AddressID) Add a DateCreated field to every table, which date stamps when the record was first entered Avoid using keywords as field names (e.g., Date, Time, Now, Delete, User, Count, Value etc.). You can, however, have them as part of a field name (e.g., DateEntered)
NEW to 2007:

Access now will warn you if you enter a field name that is a key word, such as Value in our CD table.

University Technology Training Center

15

LESSON 2: BUILDING A DATABASE

IN

ACCESS

Data Type options:


AutoNumber: Auto incrementing number used for Primary Keys. Number: Can contain only numeric values that you may need to use in

calculations, also used for all Foreign Keys.


Text: Allows for Alphanumeric data (letters, numbers, characters, etc.). Text

is the default data type. The default width is now 255, which is the maximum.
Memo:Alphanumeric Text field that allows for 65,535 characters. Use when

you need a very long note or description field.


Date/Time: Contains a date and/or time value. Dates are automatically

validated against the calendar. Date formats are determined by the Regional Settings on each PC. If those settings have been changed, you may get unexpected results.
Yes/No: Displays as a checkbox and stores one value (yes or no, true or

false). Access stores a No value as 0 and a Yes value as -1.


OLE Object: Used for storing files from other applications (pictures,

spreadsheets, etc.).
Hyperlink: A link to a website, network document, or for sending to an email

address (if you include mailto: in front of the email address).

Description:
Optional wording to describe what the field is used for. This information will show up on a form as a screen tip if you hover over the field so it can also be used as tips for data entry.

1. Create the following tables in Design View

tblMember , which we have already started tblMemberAddress tblCD

16

University Technology Training Center

2. Enter the fields and their data types. You can select the data type by

picking from the list, or you can just start typing the word and it will find and display the closest matching data type for you.

3. Once you have entered all the fields and their corresponding field types, close and save the table design. You will be asked to confirm

design changes on a table, form etc.

4. Click Yes 5. To create another table click on the Create tab on the Ribbon

University Technology Training Center

17

LESSON 2: BUILDING A DATABASE

IN

ACCESS

6. Then Click Table

7. Switch to Design View

8. Save this table as tblMemberAddress

18

University Technology Training Center

Note:

Fields such as Zip and phone are created as text fields instead of number fields in order to apply input masks for controlling the data entry format (also in case you need to enter foreign Zip codes.)
9. Repeat for tblCD

Note:

If you use Value instead of CDValue you would get the following message:

Click OK and correct the field name.

University Technology Training Center

19

LESSON 2: BUILDING A DATABASE

IN

ACCESS

Exercise 1: Creating Tables


Create the following tables and save them as the table names given.
1. Create Tab Table 2. Switch to design view and create the following table:

3. Save and close tblGenre 4. Repeat for the following 2 tables:

End of Exercise

20

University Technology Training Center

Creating a Join Table


The Join Table is necessary for our many-to-many relationship. It has the usual Primary Key plus two Foreign Keys pointing back to the tables in the many-to-many relationship. It also contains another Foreign Key pointing to the Member table again, except this time it is tracking which Member the CD is loaned out to at the time. We cant use MemberID again so we will call it LoanedToID. A join table is created in the same way as any other table, using design view.
Best Practice

The Join Table name should be a combination of the two many-tomany tables. The Primary Key can be the Join Table name or first initial of each table name followed by ID.

Note

When working with an existing database, you may or may not see some form of object-naming conventions and proper field/table names. Changing the names of tables and fields may affect many areas of your database, from relationships to forms and reports to possible VBA code behind the scenes. Use extreme caution when changing names if you are not sure where an object is used and how to correct errors that may surface after such a change.

University Technology Training Center

21

3
Lesson
Lesson 3

Setting Field Properties


There are more options we can set besides data types on our fields. These options allow us to control or improve data entry such as limiting field sizes, adding formatting for phone numbers, or auto filling common values into fields.
Best Practice

Set all the format properties and options at the table-level so they propagate through the forms, queries, and reports.

The General Tab


The bottom section of the Table Design View screen has two tabs. The General tab content varies based on the data type of the field currently selected. In the General tab, you can set field properties such as size, format, Input Mask, default value, etc. The Lookup tab is used for creating lookups for foreign key fields to the corresponding primary key.

General tab for a Text field

University Technology Training Center

23

LESSON 3: SETTING FIELD PROPERTIES

General tab for a Number field

Resizing text fields


The default number of characters for text fields in Access is now 255, which is the maximum for a text field. In most cases that is too large and will waste hard drive space. At the beginning of class we set that property to a more reasonable and space saving number of 35. That is still too large for some fields, and too small for a few others. You can also use the length of the field to control what is entered into the field.
NOTE:

If you are working with a table that has data in it already, you may cut off existing data in that field if it is longer than the new field size you select. Access will display a warning message before it applies the change so you have a chance to cancel.
1. Open tblMemberAddress in Design View by right clicking on it and choosing Design View 2. Select the State field 3. Click on the Field Size value in the General tab 4. Change the value to 2

24

University Technology Training Center

5. Repeat the same for the following fields:

Zip:

Field size of 9 (to allow for ZIP + 4) Field size of 10

Phone:

Input Masks
Input Masks are used for consistent data entry and formatting of dates, phone numbers, and zip codes. Added characters (/ - ( ) , etc.) are for display onlythey are not saved as part of the data value. The field must be text, not numeric. If the Input Mask is added later, it will only show formatting correctly if it consists of straight numbers with no preexisting formatting. If you are working with existing data that has characters in the field (such as / or -), remove the extra charactersmanually or by using a Search/Replaceand the data will then correctly display with the chosen input mask.
1. Select the Phone field in tblMemberAddress 2. Click in the Input Mask field in the General tab.

University Technology Training Center

25

LESSON 3: SETTING FIELD PROPERTIES

The

(ellipses) button will appear to the right of the field

3. Click on the ellipses button to display the Input Mask Wizard 4. You will be asked to save changes made to the table design

5. Click Yes 6. The input mask wizard will appear. Choose the Phone Number option

(first one in the list)

26

University Technology Training Center

7. In the Try It section, type in a phone number and see how it works.

Note:

With all Input Masks, if you tab into the field, the cursor will start at the beginning. If you click in the field, it will start wherever you click, and you have to move to the beginning of the field in order to type the data correctly into the Input Masks format.
8. When you are done testing the Input Mask, click Finish. This is what

the phone number input mask will look like in the general tab.

University Technology Training Center

27

LESSON 3: SETTING FIELD PROPERTIES

Default values
Default values can save data entry time for a field where most of the records entered will have the same value (i.e., most of the CD Club members will be from Minnesota). The value entered can be easily changed for the exceptions that occur. A default value will only be present in new records. Existing records will not be affected. In order for our DateCreated field in each table to work, we need to add a command into the default value. Default values apply only to new records. So every time there is a new record, we want to put in todays date automatically.
1. Select the State field in tblMemberAddress

2. In the Default Value field on the general tab, type MN

28

University Technology Training Center

3. When you tab off the field it will put double quotes around the value.

4. Choose the Country field 5. In its default value type USA 6. Select the DateCreated field 7. In the Default Value field, type Date()

Note:

Be sure to include both parentheses! This will date stamp the creation of a new record when it is added to the table. If you wanted to be more precise, you could use the command Now() , which includes both date and time.

University Technology Training Center

29

LESSON 3: SETTING FIELD PROPERTIES

Format number fields


Integer (the default number type) does not allow decimal places and will automatically round up or down even if you specify it should have 2 decimals. If you need to have decimal places in a number value, you will need to use the Single or Double formatdepending on how large the number entered will be.
Byte: 0 to 255 (rounds up or down) Integer:

-32768 to 32767 (rounds up or down, default number type)

Long Integer: Single: Double:

-2,147,483,648 to 2,147,483,647 (rounds up or down, default for Primary Key auto number fields) -3.4x1038 to 3.4x1038 (up to 7 decimal places, will not round) -1.797x10308 to 1.797x10308 (up to 15 decimal places, will not round)

Prevent rounding of numbers with decimals


1. Open tblCD in Datasheet View by double clicking on the table name in the Object Navigation Pane on the left side

2. Type 14.99 in the CDValue field.

30

University Technology Training Center

It will round up to 15 because by default it is an integer type.


3. Hit ESC to undo the data entry 4. Change to Design View of tblCD by clicking on the View toggle in the

upper left.
5. Click on the CDValue field to select it 6. Change the DataType to Currency

7. Switch back to Datasheet View and type in 14.99 . It will now display

as $14.99 and will not round.

8. Hit ESC to undo the data entry. 9. Close and Save the design changes to tblCD

University Technology Training Center

31

LESSON 3: SETTING FIELD PROPERTIES

Exercise 2: Setting field properties


Complete the formatting of the fields in Design View of the following tables:
1. In tblMember

Add the Date() command into the default value for DateCreated Add a Short Date Input Mask to the Birthday field Add the Date() command into the default value for DateCreated Apply the Zip Code mask to the Zip field

2. In tblAddressType

3. In tblMemberAddress

4. In tblGenre

Add the Date() command into the default value for DateCreated

5. In tblPerformer

Set Performer to a length of 100 Add the Date() command into the default value for DateCreated

6. In tblCD

Set Title to a length of 100 Add the Date() command into the default value for DateCreated

7. In tblMemberCD

Add a Short Date Input Mask to the DateOut field Add the Date() command into the default value for DateCreated

End of Exercise

32

University Technology Training Center

4
Lesson
Lesson 4

Creating Relationships
In Access, you create the relationships between tableswhich youve previously defined on papervisually through the Relationship Window. Setting up the relationships here tells Access how the tables within this database are linked to each other. If you set up the relationships this way, the links between tables will carry through anytime you use the tables in a form, query, or report.
8. Click on the Database Tools Tab 9. Click on Relationships

University Technology Training Center

33

LESSON 4: CREATING RELATIONSHIPS

10. The Show Table dialog box will appear. Select all tables in the database

at once by holding down your shift key and click on the first table in the list, then the last table.

11. Click Add then click Close

Note:

If the Show Table dialog box is not open, you can right click in a blank section of the relationships window and choose Show Table

or use the Show Table button on the Design tab

12. Once you have all the tables showing in the window, you can

rearrange them to look like your paper diagram by simply dragging them around the window.

34

University Technology Training Center

Create the lines to connector relatethe Primary Keys to their respective Foreign Keys, as on our paper diagram.
13. Click on the Primary Key in one table and drag it over to the Foreign Key in the related table. When you release the mouse you will see the Edit Relationships dialog box.

Verify you have selected the correct fields!

Important Notes!

These fields must be of the same data type to be related. If not, you will get an error message and will have to return to the table design and make the necessary corrections. Only one relationship is allowed between any two tables.
14. Select Enforce Referential Integrity

On the Edit Relationships window, there is an option that should be checked for all tables: Enforce Referential Integrity, which prevents a record from being

University Technology Training Center

35

LESSON 4: CREATING RELATIONSHIPS

deleted in one table when there are related records in the other table. This option aids in data integrity by not allowing deletion of data creating orphan records. For example, you wouldnt want someone to delete a CD from the database that multiple people own and may be out on loan.

Note:

In Access 2003, setting Referential Integrity also acted as a required field setting. Setting Referential Integrity between Genre and CD, for example, will prevent you from adding a CD record without selecting a Genre as well. If you have data in the tables already, Access will not allow you to set Referential Integrity until all records meet this requirement. This was not the case before 2003 and has been changed back in 2007 so that it does not create the required field property.
15. Click Create 16. Repeat for all tables in the database

17. Close and save your relationship design

36

University Technology Training Center

Print the design


You can print out the design to reference as you are working on the database, to keep track of changes made or to present to a manager or end user.
1. Return to the relationships window using the Database Tools tab.

2.

Select the Relationship Report

3. Switch to Landscape layout

4. After you have printed the report close the report preview window using the X in the upper right hand corner.

University Technology Training Center

37

LESSON 4: CREATING RELATIONSHIPS

5. Choose No when it asks to save the report.

Removing Tables from the Diagram


If you accidentally add a table to the window more than once, it will add the table again and name it [tablename]_1. To remove the extra table, just select the table and hit Delete. (You are not deleting anything from the database itself.)

Deleting or Editing Relationships


Double click on the relationship line drawn between two tables to edit the relationship. Right clicking on the line will also give you the Edit option, as well as the option to delete the relationship. Removing a table from the relationships diagram that has a relationship link to another table will not remove the relationship itself. To completely remove the relationship, you have to delete the relationship before you remove the table from the diagram.

38

University Technology Training Center

5
Lesson
Lesson 5

Modifying Tables and Relationships


Often in the process of creating the tables and relationships, in the refine and test stage, you may find that you need to rethink part of your design. Its a good idea to consider having a status field in your main table of the database (in our case tblMember). The primary reason is after a while the number of records in the table will increase, all those records in a drop down or a form could slow things down. If you only want to show current members you can filter out anyone else and shorten up that list again, rather than deleting the inactive members and losing the history.
1. Open CDClub.accdb from your desktop 2. Click on the Create tab

3. Then click Table

University Technology Training Center

39

LESSON 5: MODIFYING TABLES

AND

RELATIONSHIPS

4. Switch to design view 5. Create the fields as shown below:

6. Edit field properties

Add the Date() command into the default value for DateCreated

7. Close and Save the table design

Adding the New Foreign Key Field


1. Add the new foreign key field MemberStatusID to tblMember

Open tblMember in design view by right clicking on the table name in the navigation pane

Right click on the DateCreated row and choose Insert Rows

40

University Technology Training Center

Add MemberStatusID as a Number type in the new row

2. Edit the Relationships

Under Database Tools, select Relationships Add the new table (tblMemberStatus) to the Relationship Window using the Show Table dialog box Link tblMemberStatus to tblMember using the MemberStatusID field Set Referential Integrity
Close and Save the relationship design changes

Updated Relationships

University Technology Training Center

41

6
Lesson
Lesson 6

Creating Interfaces to Interact with Data


Using Forms vs. Tables for data entry
Once you have your tables created and relationships set, you can move on to creating the forms. Forms are used to enter, view and edit data in the tables. You should not enter data directly into the tables themselves. Regardless of if it is a database you created, one that has been purchased, or one set up by someone else. All database programs can have data integrity issues caused by adding, editing, or (worst case scenario) deleting information in a table. Tables are meant to be behind the scenes, not directly interacted with. Dont think of the tables as Excel spreadsheets. They are the backbone of your database and should not be used for data entry. Software programs containing a database backend will usually not even allow you access to the tables. All interactions with the data are done through forms and queries. Often forms in an Access database have additional calculations or automation code within them that will not run if data is entered into a table directly. Forms will also keep track of all the Primary and Foreign Key relationships for you. An end user would have a hard time knowing what key value a particular field in a related table has. Access is more suited to managing the tables and keys itself.

Example of a table with multiple foreign keys after data is entered through a form.

We will examine 4 methods for creating forms in Access 2007 along with the ability to update the values in a lookup table on the fly when doing data entry on a form.
University Technology Training Center 43

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Creating the Member Status type Entry Form


From this point use the cdclubTables database from our class files folder.
1. In the object navigation pane, click on tblMemberStatus (the table

name that is currently highlighted will be used for the source of the form).
2. Select the Create tab 3.

In the Forms section, select the Multiple Items icon

Types of Forms
Single/Columnar Form: Displays one record at a time. Multiple Item/Continuous/Tabular Form: Displays as many records

as will fit in the detail section of the form. As you type in one record, a new record is started below. The multiple items form is most often used for the lookup tables to create an easy form to maintain the values in those tables.

This method of form creation automatically selects all fields from the table and displays them on the form in Form View.

44

University Technology Training Center

4. At this point the basic form is ready for data entry. Enter the following

values: Active Inactive

Note how the icon to the left changes to a Pencil symbol and a new record is created below as soon as you start typing in the Member Status field. The primary key ID is also assigned at this point. The Pencil means this record is currently being edited. Once you leave that record, it is automatically saved, and it moves to the next record.
5. Make note of what MemberStatusID number gets assigned to

Active, we will need that later in this exercise.


6. We can edit this form in design view by selecting the Home tab, then

using the view toggle button.

Design view of a form

University Technology Training Center

45

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

When you open the form in design view initially it may show all the fields and labels with an orange border. This means they are currently grouped together. To ungroup them, click anywhere in the form outside of the grouping.
7. Edit the form title in the form header by clicking once to select the

field, then clicking again on the text of the field to go into edit mode. Remove tbl and put a space between Member and Status

8. Remove the MemberStatusID field. This field does not need to be shown

on the form.

Select the field and hit Delete on your keyboard.

Access automatically repositions the other fields after you remove a field. 9. Put spaces in the field names to separate the individual words in the

labels that are in the header section.

46

University Technology Training Center

Important Note!

You can edit the label (the transparent box), but you cannot edit the text box (the white box). The text box is the actual field name that the data entered will be saved into. If you change or delete the content in the white box, Access will not know where to save the data entered on the form. If you do accidentally change the field name, Access 2003 and later will mark the field and give you suggestions to fix the error. For example, if you change the MemberStatus field to Member Status, the field will show a green triangle in the upper left corner.

Click on the triangle to produce a yellow exclamation sign. Click on it to see the Access tips for fixing the problem.

The highlighted fields are the applicable errors. Listed below are possible solutions. In this case, the solution would be to Edit the Controls Control Source Property and choose the correct field (or simply remove the space so it is a valid field name).

University Technology Training Center

47

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Locking the Field


Because the Date Created is automatically filled in, and we would not want someone to accidentally or purposely change it, we will lock that field from being edited.
1. Right click on the DateCreated Field in the detail section of the form and choose Properties OR double click on the field 2. On the Property Sheet Data tab change Enabled to No and Locked to Yes

Note about Enabled and Locked Properties

The Enabled and Locked properties can be used together or independently depending on the desired outcome.
Enabled=No

will lock and grey out the field

Locked = Yes will lock the field but not grey it out. The field is

selectable and can be copied. It can cause confusion on the end users part because it acts like one should be able to type in the field will lock the field but not grey it out and not allow a cursor into the field.
Enabled=No AND Locked = Yes 3. Return to form view using the View toggle to see the changes made. 4. Close and Save the form as frmMemberStatus

48

University Technology Training Center

Setting Active as the default Member Status


If we want all new members to automatically be assigned an Activestatus we can set the default property in the MemberStatusID field in tblMember.
1. Open tblMember in design view 2. Select the MemberStatusID field 3. In the General tab, under Default Value, type in the number we wrote

down earlier as being assigned to the Active status.

4. Close and save tblMember

University Technology Training Center

49

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Exercise 3: Creating Entry Forms Using Multiple Items Form Option


Part 1:
Performer entry form: We need to enter the performers ahead of time in

order for them to show up in combo box used to create a CD record. This form is used to add and edit the values in tblPerformer.

1.

In the Object Navigation pane, click on tblPerformer

2. From the ribbon menu choose Create 3. From the Forms section choose Multiple Items

50

University Technology Training Center

4. Switch to Design View using the View Toggle on the Home tab 5. Edit the Label in the header of the form to remove the tbl 6. Delete the PerformerID field 7. Put spaces in the DateCreated label 8. Lock down the DateCreated field using the field properties (set

Enabled to No and Locked to Yes)

9. Save and name the form as frmPerformer 10. Switch to Form View and enter test data:

Enya Garth Brooks Green Day Ludwig van Beethoven Ralph Stanley

University Technology Training Center

51

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Part 2:
Address Type entry form: We need to enter the Address Types ahead of

time in order for them to show up in combo box used to create an Address record. This form is used to add and edit the values in tblAddressType.

1. In the Object Navigation pane, click on tblAddressType 2. From the ribbon menu choose Create 3. From the Forms section choose Multiple Items

4. Switch to Design View using the View Toggle on the Home ribbon

menu
5. Edit the Label in the header of the form to remove the tbl and put a

space between address and type


6. Delete the AddressTypeID field 7. Put appropriate spaces in the AddressType and DateCreated labels

52

University Technology Training Center

8. Lock down the DateCreated field using the field properties (set

Enabled to No and Locked to Yes)

9. Save and name the form frmAddressType 10. Switch to Form View and enter test data:

Home Work School

End of Exercise

University Technology Training Center

53

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Handling One-to-Many Relationships with Subforms


A subform is a form within another form. A form-to-subform relationship can be defined as a parent/child relationship. A subform is the best method of showing records from the table on the many side of the one-to-many relationship. For the record currently displayed in the main form, many records can be shown on the subform. One example of this in our database is the members and their addresses. We opted to allow multiple addresses for each member. The main form shows one member from the member table, while the subform displays all of the address in the member address table associated with that members ID. Create a form to enter members with a subform to enter multiple addresses for each member.

Member Form
The member form is the main form that shows one member record at a time.

1. In the object navigation pane select tblMember 2. Choose the Create tab

54

University Technology Training Center

3. Under the Forms section choose Form

Newly created member form 4. Go to the Home tab and Switch to Design View

frmMember in Design View

University Technology Training Center

55

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

5. Click outside the field grouping to ungroup them 6. Edit the top label in the header to read Members instead of tblMember 7. Edit the field labels to add spaces between the words

Put a space between Member and ID

We wont delete the key field in this case since the MemberID could be referenced and searched by within the database (like an account number)

Put spaces between First, Middle, and Last and Name Put a space between Date and Created

8. Replace MemberStatusID with a combo box that looks up the values from tblMemberStatus

Select the MemberStatusID field and click delete From the Design Tab click on the Combo Box object to select it (it will place an orange border around the selected object).

Move your mouse to the location on the form that you want to place the object, in this case - below the Date Created field. (Your mouse icon will change to the icon for the object you have selected).

56

University Technology Training Center

The combo box wizard will appear, leave the default option, click Next

Select tblMemberStatus and click Next

Move MemberStatusID and MemberStatus fields into the selected fields area by double clicking or using the > button, click next.

University Technology Training Center

57

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Note: When creating a combo box the Primary Key of the lookup table should always be the first field and the text field the user will actually see and pick from should be the second field. Select MemberStatus as the field to sort by, click next

The next screen is a preview of what the drop down box contents will be. Here you can make the column(s) wider or narrower as needed. Note that the Primary key (the first field we selected) is automatically hidden from the user.

58

University Technology Training Center

This step is critical, we must tell Access where to store the selection we make. The combo box stores the value of the primary key which needs to be saved to the corresponding foreign key in the table the form is based on. Use the dropdown to select the matching foreign key field MemberStatusID, click next.

Type in the text you want for the label part of the combo box: Member Status, click Finish

University Technology Training Center

59

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

9. Move the newly created combo box below the Birthday field. Access

will automatically move the DateCreated field down to accommodate for it and reformat the field to match the others.
10. We need to shorten the fields to make room to add a subform. Group

all of the fields in the detail section Click anywhere above the MemberID Field (not the label, we dont want the labels included in this grouping) Drag your mouse down and to the right until all fields are within the box it has created.

11. Let go of the mouse and all the fields will be grouped and showing

the orange border

Make sure that the labels to the left of the fields are not included in the grouping (not outlined in orange) 12. Hover over the right side and get the double arrow, then drag the

group to the left to shorten all the fields at once.

60

University Technology Training Center

13. Release your mouse around the 4 inch mark

14. Lock down the DateCreated field by setting enabled to no and locked

to yes in the fields properties


15. Close and Save the form as frmMember

University Technology Training Center

61

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Exercise 5: Creating a Subform using Autoform


Member Address Subform
Used to enter multiple addresses for a member once it is connected to the member form.

1. In the object navigation pane select tblMemberAddress 2. Choose the Create tab 3. Under the Forms section choose Form

62

University Technology Training Center

4. Go to the Home ribbon menu and Switch to Design View 5. Click outside the field grouping to ungroup them 6. Edit the top label in the header to read Addresses instead of tblMemberAddress 7. Delete the MemberAddressID and MemberID fields 8. Replace the AddressTypeID with a combo box

Delete the AddressTypeID field Select the Combo Box option from the design tab and place it under date created on the form Select tblAddressType Select AddressTypeID and AddressType

Sort by AddressType Store the value in AddressTypeID Type Address Type for the label text

University Technology Training Center

63

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Move the newly created combo box above the Address1 field.

9. Edit the field labels to add spaces between the words

Put spaces between Address and the 1, 2 or 3 Put a space between Date and Created

10. Group all of the fields in the detail section

Click anywhere above the AddressTypeID Field (not the label, we dont want the labels included in this grouping) Drag your mouse down and to the right until all fields are within the box it has created.

11. Let go of the mouse and all the fields will be grouped and showing

the orange border

Make sure that the labels to the left of the fields are not included in the grouping (not outlined in orange)

64

University Technology Training Center

12. Hover over the right side and get the double arrow, then drag the

group to the left to shorten all the fields at once.

Release your mouse around the 3 inch mark

University Technology Training Center

65

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

13. Because this is a subform, we want it to be compact. We also need to shrink

the size of the form itself (the area with the grid behind it). You may have to scroll to the right to see the edge of the form.

14. Hover over the right edge of the form and get the double arrow with

the vertical line.


15. Drag the side of the form up to the right edge of the fields and release.

Oops! It didnt work. The box for the addresses label is very large and needs to be shrunk as well.

66

University Technology Training Center

16. The easiest way to do that is to right click on the Addresses label in

the header and choose Size To Fit

17. Then repeat step 13.

University Technology Training Center

67

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

18. Lock down the DateCreated field by setting enabled to no and locked

to yes in the fields properties


19. Close and Save the form as subfrmMemberAddress (use the

subfrm prefex for all sub forms)

Note:

You should not enter an address in the subform as it is right now. You need to have it linked to the main form first to know what member the address belongs to. We will do that in the next step together.

End of Exercise

68

University Technology Training Center

Linking the Main form and Sub Form

This step is similar to setting the relationship between two tables. We need to tell Access which primary key/foreign key fields link the two forms. This method also allows Access to maintain the Primary and Foreign Key values that are used to match the addresses with their respective members.
1. Open frmMember in Design View 2. In the Design tab in the Controls section click on Subform/Subreport

3. Click in the detail area to the right of MemberID 4. From the subform wizard click on Use an Existing Form

University Technology Training Center

69

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

5. Choose the subfrmMemberAddress form Click Next

6. In the Define Link form, choose the Show tblMemberAddress for each record in tblMember using MemberID option Click Next

If the show statement is cut off in the selection window you can see the full statement right below.

70

University Technology Training Center

7. Leave the name subfrmMemberAddress for the form name Click Finish

8. Select the subfrmMemberAddress text box created as a title for the subform and press Delete on your keyboard.

9. Save the design changes to form. 10. Switch to Form view

University Technology Training Center

71

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Navigating Records and Entering Test Data


Navigating Records
To move between records, use the navigation bar at the bottom of the form.

First Previous Next Last New Record When you have a subform you will have a second set of navigation buttons to move through the subform records.

1=Main form, 2=Subform

Entering Test Data


1. Enter in your name and birth date in the main section of the Member

form
2. In the addresses subform, choose Home as the address type and enter

in your home address


3. Click on the Next button in the subforms navigation bar 4. Choose Work or School as the address type and enter another address

for yourself
5. Click on the Next button of the main Members form and repeat for

another member. Enter a friend, relative, or made up member with two different addresses

72

University Technology Training Center

Creating Forms using the wizard


Genre Form

This form will be used to enter values into the Genre Lookup Table for use when entering CDs.
1. On the Create ribbon menu choose More Forms Form Wizard

2. Choose tblGenre from the dropdown list

University Technology Training Center

73

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

3. Select the fields that you want to see on the form by using the >

button.

In this case we want Genre and DateCreated

4. After the 2 fields are under the Selected Fields area, click Next 5. Choose the Tabular option (multiple items/continuous type of form), click Next

74

University Technology Training Center

6. To make this form match our previously created forms choose the Access 2007 style, click Next

7. Name the form frmGenre and click Finish

8. From the Home menu, switch to Design View 9. Remove frm from the frmGenre label 10. Widen the Genre field and label 11. Lock down the DateCreated field by setting enabled to no and locked

to yes in the fields properties


12. Save the design changes and switch back to Form view

University Technology Training Center

75

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Modify Formatting
1. Enter test data:

Country Rock Pop New Age Jazz Classical

Note the Alternating lines created with this style of creating a form.
2. If we want to turn that off to match the style of the other forms we

have created, go to design view and right click on the detail section bar

3. Hover over Alternate Fill/Back Color and select None to remove it.

76

University Technology Training Center

Exercise 6: Creating the CD entry form using the Wizard

1. On the Create tab choose More Forms Form Wizard

2. Choose tblCD from the dropdown list

University Technology Training Center

77

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

3. Select the fields that you want to see on the form by using the >

button.
PerformerID GenreID Title YearReleased CDValue DateCreated

4. After the desired fields are under the Selected Fields area, click Next 5. Choose the (default) Columnar option (Single form), click Next

78

University Technology Training Center

6. To make this form match our previously created forms choose the Access 2007 style, click Next

7. Name the form frmCD and click Finish

8.

From the Home tab, switch to design view

9. Remove frm from the frmCD label 10. Remove the PerformerID field and replace with a combo box

Select PerformerID and Performer from tblPerformer Sort by Performer Save selection to the PerformerID field Label as Performer
79

University Technology Training Center

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

11. Remove the GenreID field and replace with a combo box

Select GenreID and Genre from tblGenre Sort by Genre Store the selection in GenreID Label as Genre

12. Space out the words in CDValue, YearReleased and DateCreated

labels
13. Lock down the DateCreated field by setting enabled to no and locked

to yes in the fields properties


14. If you want to have the fields in a different order (more logical for

data entry), simply drag them up or down in design view. Move the title field to the top, followed by Performer, Genre, Year Released, Value and Date Created

The other fields automatically adjust for you.


15. Shorten all fields and the form itself so it is more compact but still has

room in the fields for the data.


16. Close and save the form End of Exercise

80

University Technology Training Center

Adding to combo box lists on the fly


1. Enter test data into frmCD: Title A Day Without Rain American Idiot Beethoven's Greatest Hits I Wonder Where You Are Tonight In Pieces Kind of Blue Man of Constant Sorrow Performer Enya Green Day Ludwig van Beethoven Del McCoury Garth Brooks Miles Davis Ralph Stanley Genre New Age Pop Classical Bluegrass Country Jazz Bluegrass Year 2004 2004 1984 2002 2002 1991 2001 Value $ 15.00 $ 16.00 $ 12.00 $ 15.00 $ 15.00 $ 15.00 $ 15.00

What happens if the Genre or Performer does not exist in the Combo Box?
Answer:

Starting with Access 2007 you will be prompted about adding the new value to the list

Click Yes and the form you specified in the field properties will open up and you can go to a new record and add the missing value. The value will be immediately available for use in the main form once you close the edit form.

University Technology Training Center

81

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

2. When you get to the first missing Performer (Del McCoury), hit esc a

couple times to clear out the data entry


3. Switch to design view 4. Right click on the PerformerID field and choose Properties 5. On the Data tab under List Items Edit Form choose frmPerformer

from the drop down list

6. Close the properties window 7. Repeat for the GenreID field, choosing frmGenre 8. Continue with the data entry

82

University Technology Training Center

9. Close and save the form

University Technology Training Center

83

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Finding a Record on a Form


You can move through the records using the navigation bar at the bottom of the form in a small record set. Once you have a large amount of records, however, it is tedious to go through them one by one to find the record you need. There are a number of ways to quickly locate a record or subset of records on your form. Searching, filtering and using a search combo box will be examined.

Quick Search
1. Open frmCD in Form View 2. Click in the search box in the bottom navigation bar 3. Start typing in a word that appears in any field on any record in the

form. As you type the word the first record that has a match will be displayed. Ex. Where, or blue. Hit enter to move to the next matching record if there are more.

84

University Technology Training Center

Filtering by Selection
1. Locate a record that has a Bluegrass CD 2. Place your cursor in the Genre field 3. On the Home tab, in the Sort and Filter section, click on Selection 4. Options will be displayed that will help you choose how to filter. Choose the Equals Bluegrass option

5. The form will show that it is Filtered and how many records it found

that matches the filter in the navigation area at the bottom of the form

The form now only shows the 2 records that have a bluegrass Genre type.
6. To remove the filter and see all records again click on Filtered and it

will change back to Unfiltered

University Technology Training Center

85

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Filtering by multiple items


1. Click in the Genre Field 2. Choose Filter from the Sort and Filter section

A Popup will display all the options for that field 3. Clear all check boxes by unchecking the Select All option 4. Select only Bluegrass and Jazz

5. Click OK

The records showing will be anything with Bluegrass OR Jazz genre types.
6. To remove the filter, click on Filtered in the navigation area at the

bottom of the form and it will change back to Unfiltered.

86

University Technology Training Center

Using a Combo Box to Find Records on the Form


If you want something more permanent and fewer steps than a filter, you can add a Combo Box that will find a single record on the form for you. The Combo Box can also be used to help avoid duplication of entries if you check existing values before adding a new record.

7.

Open frmCD in Design View

8. From the Design menu Controls section click on the Combo box icon

9. Click in the form header section next to the CD label (leave enough

room for the combo box label in between)


10. From the Combo Box wizard, choose the third option Find a record on my form based on the value selected in my combo box Click Next

University Technology Training Center

87

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

11. Add the CDID , Title , and Year Released fields to the Selected

fields window Click Next

12. Expand the Title field Click Next

88

University Technology Training Center

13. Name the Combo Box Find CD Click Finish

14. Use the Font Size and Bold options on the toolbar to make the Find CD label Bold and 14 point 15. Expand the width of the Combo Box and the label

16. Switch to Form View and test the combo (lookup) box 17. The list currently is not sorted, to make this function work better we

need to sort by the CD Title (the field you would be typing a value for) Switch back to Design View Right click on the combo box and choose Properties On the Data Tab click in the Row Source field Click on the Ellipsis button at the end of the field

University Technology Training Center

89

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

Choose Ascending in the sort row under Title Close and Save the Query

18. Switch to form view and search for a CD by typing in the start of a

Title or drop the list down and make a selection


19. Save and close the form

90

University Technology Training Center

Creating the Member CD Form and Subform in Design View


We will create the form and subform to track each members list of CDs that they own, and the loaning of those CDs to other members, from scratch using design view.

Creating the Member CD Main Form


1. From the Create tab, in the forms section choose Form Design

University Technology Training Center

91

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

2. Click on Property Sheet

3. On the Data Tab, use the drop down for Record Source to choose tblMember (the table this form needs to be based on)

4. Close the Property Sheet 5. From the Tools section choose Add Existing Fields

92

University Technology Training Center

The field list is divided into 3 sections: Fields from the table you chose as the record source, fields from tables related directly to that table and the rest of the tables in the database. You can change the view to only show fields from the table you selected by clicking on at the bottom of the field list.

University Technology Training Center

93

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

If you select records from a table other than your record source it will change to the record source to a query joining the appropriate tables. This may produce undesired results. You can return to seeing all tables by clicking on Show all tables at the bottom of the field list.
6. Select the FirstName field and drag it onto the form

7. Drag LastName onto the form to the right of FirstName

8. Put spaces in the labels between the words

94

University Technology Training Center

9. Close and Save the form as frmMemberCD (you will come back to

it later to add a subform)

Creating the Member CD Subform


This form allows for all the CD titles owned by the member in the main form to be displayed or added to. It is also used to show if a CD is currently out on loan, to whom and when it was loaned out.
1. From the Create menu ribbon, in the forms section choose Form Design

2. From the Property Sheet choose tblMemberCD as the Record Source

3. Create a Combo Box for the CD selection

Base the combo box on tblCD Select the fields CDID, Title and YearReleased (in that order) Sort by Title Save the selection to the field CDID Label as CD Widen the field

University Technology Training Center

95

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

4. Create a combo box for the Loaned To field to the right of the CD

field

Base the combo box on tblMember Select the fields MemberID, LastName and FirstName (in that order) Sort by LastName Save the selection to the field LoanedToID Label as Loaned To

5. Click on Add Existing Fields

Drag the DateOut field from the field list to the right of the Loaned To field

6. Change the form to a Continuous Form (multiple item type of form)

Click on the Property Sheet in the tools section Make sure the drop down says Form, if it is anything else change it to Form

Switch to the Format Tab

96

University Technology Training Center

Use the dropdown to change the default view from Single Form to
Continuous Forms

7. Close the properties window 8. Shrink the form up from the bottom so it is just bigger than the fields

(or it will leave a lot of white space in between each record)

9. Close and save as subfrmMemberCD

Link the main form to the subform


1. Open frmMemberCD in design view 2. Add subfrmMemberCD using the Subform option from the Controls

3. In the subform Wizard, choose the existing form subfrmMemberCD 4. Link the form and subform by the common key field MemberID 5. Finish the subform wizard 6. Back at the form design view, delete the label above the subform 7. Expand the border of the subform downward to make room to show

multiple records

University Technology Training Center

97

LESSON 6: CREATING INTERFACES

TO

INTERACT

WITH

DATA

8. Save the design changes and switch to form view 9. Use the MemberCD form to loan a CD to another member in the

club, including filling in the Date Out field. (If there are no other members listed in the Loaned to dropdown, add another member through the Member form.)
Did you notice?

We chose two fields for the Loaned To Combo Box, but only one showed up after you chose the member. When you drop down the item, you will see all the fields, but only the first field after the Primary Key ID will display once selected. If you would rather see the first name instead of the last, recreate the Combo Box, choosing the Primary Key first and then FirstName followed by LastName.

98

University Technology Training Center

Date picker
The date picker is a new feature to Access 2007, it is a popup calendar you can use to enter a date into a field instead of manually typing in the numbers. The icon will show on forms and reports next to a date field currently being edited. It also has a handy Today button at the bottom to easily select the current date.

The Date Picker will not be available if there is an input mask on the date field. That is the case with our Date Out field. If we want to use the calendar to select a date for this field we have to go back to the table and remove the Input mask from the field.
1. Open tblMemberCD in design view 2. Select the DateOut field 3. On the General tab, clear out the value in the Input Mask 4. Close and save the table design changes 5. Try it out on the form

University Technology Training Center

99

7
Lesson
Lesson 7

Editing a Form
The Member CD form and subform we created in design view do not match the style of the forms we created using the automated tools. We can edit that form and assign a format to it and add a label in the header.

Modifying a Form
1. Open frmMemberCD in Design View 2. Go to the Arrange tab 3. In the Show/Hide section choose Form Header/Footer

New form header section has been added

University Technology Training Center

101

LESSON 7: EDITING A FORM

4. From the Arrange tab choose Autoformat

5. Choose the Access 2007 format that we used in the prior exercises (if

you hover over the thumbnail it will give you the format name, it is the second one in the first row)

6. Expand the form header section downward

7. Switch back to the Design tab and select Label

8. Drop the label in the header and type in Member CD List

102

University Technology Training Center

LESSON 7: EDITING A FORM

9. Change the font and size to the following:

10. Right click on the label and choose Size to Fit

We should also lock out both the first name and last name fields from being edited. Members should only be added through the Member Form.
11. Select both fields at the same time by holding down your shift key. 12. Click on Property sheet on the Design tab 13. Set Locked to Yes on the Data Tab of the Property sheet

If you set both Enabled to No and Locked to Yes, you will not be able to search on that field
14. Close and Save the design changes

University Technology Training Center

103

LESSON 7: EDITING A FORM

104

University Technology Training Center

8
Lesson
Lesson 8

Queries
From this point use the CDClubForms database. After data has been entered using the forms, you can use queries to ask questions of your database. You can view and analyze fields from one table or join multiple tables together. A common reason for creating a Query is simply to join tables together to view related content. Queries are generally the basis of reports as well. Use the query to pull the fields and narrow down to the records desired, the report just formats the data for printing.

Creating a Query using the Query Wizard


CD List with Owners
The goal of this query is to create a master list of all CDs that are owned by the members and who owns them. We need to pull information from several tables to include all the fields needed for the query results.
1. On the Create tab choose Query Wizard

2. Leave at the default of Simple Query Wizard, click OK

University Technology Training Center

105

LESSON 8: QUERIES

3. In the Tables/Queries dropdown select tblCD

4. Add Title and YearReleased fields to the selected fields area 5. Switch to tblGenre

6. Add the Genre field to the selected fields 7. Switch to tblPerformer 8. Add the Performer field to the selected fields 9. Switch to tblMember

106

University Technology Training Center

LESSON 8: QUERIES

10. Add the FirstName and LastName fields to the selected fields

11. Click Next

OOPS!

In order for Access to know how these tables are related, and to pull fields from several tables in this query wizard, the tables have to be set up in the relationship design. In this version of the database, one relationship has been left out.
12. Click OK and it will show the relationships window 13. Close the show table dialog box 14. Recreate the missing relationship between tblGenre and tblCD

University Technology Training Center

107

LESSON 8: QUERIES

Dont forget to set Referential Integrity

15. Close the relationship window and start over at Step 1 of this Exercise 16. Leave the default of Detail and click Next

17. Save the Query as qryCDListWithOwners

108

University Technology Training Center

LESSON 8: QUERIES

Be descriptive in the query and report names, you may end up with several that are similar and you will want to be able to easily identify the purpose of the query or report just by looking at the name of it.

The query initially opens showing the results in query view

Modify a Query Using Design View


1. Switch to Design View using the view toggle

University Technology Training Center

109

LESSON 8: QUERIES

Did you Notice?

tblMemberCD is included in the query even though we did not select any fields from that table. We cannot make a connection directly from tblCD to tblMember. When we set up the relationships, we told Access that tblMemberCD is needed to join the two tables, so Access automatically added tblMemberCD into the query design.
2. Add a new field to the query to combine the Last and First Name

fields into one field called Owner. This field exists only within this query In the next blank column, type Owner :

The colon signifies that this is a new field name) The , [space] between the fields leaves a comma and a space between the values so they do not run together)

After the colon type LastName &, & FirstName .

Once you tab off the field, Access will add [ ] around each field name.

If you are working in a database that has spaces in the field names, you must put in the brackets manually, or Access will see each word as a field

3. Delete the original Name fields by hovering above the FirstName

column until you get a downward pointing arrow. Drag across to the Lastname column so both are highlighted. Then hit the Delete key

110

University Technology Training Center

LESSON 8: QUERIES

4. View the query results. Note that the new column name is the name we

gave the field.

5. Close and Save the Query design changes

Queries are dynamic, meaning as the data changes, the query results will change. If you query for a list of all the CDs in the club database today, and then again in a month, any CDs added, edited, or removed in the next month will change the query results. If Prince changes his name, for example, it will be reflected in the new results.
6. Open the Performer form 7. Find the record for Prince 8. Change the value from Prince to Artist Formerly Known as Prince 9. Double click on qryCDListWithOwners to run the query

Note the name change is reflected in multiple records even though you only changed it once

Before

After

University Technology Training Center

111

LESSON 8: QUERIES

Exercise 7: Creating a Query Using the Wizard


CD Master List
The CD List with Owners query shows multiple records for some CDs. This is because more than one Member owns that CD. We avoid having the CD information stored in the table multiple times by setting up the proper relational database structure, but we display it for every instance in the query results. To see just a unique list of all available CDs in the club dont include anything from the Member table.
1. In the Query objects, click on Create Query using Wizard 2. Pull fields from tblCD Title CDValue YearReleased

3. Switch to tblGenre and add the Genre field 4. Switch to tblPerformer and add the Performer field Click Next 5. Leave the default of Detail Click Next 6. Name it qryCDMasterList 7. Click Finish and the Query will open showing the results

112

University Technology Training Center

LESSON 8: QUERIES

Add a Sort to a Query


It might be hard to tell at this point that there is only one record per CD, so we can add a sort to the query.
1. Switch to Design View 2. In the Title column Sort row, choose Ascending from the drop down

3. Switch back to the query results view. Now the CDs will be in order

by Title

End of Exercise

University Technology Training Center

113

LESSON 8: QUERIES

Adding Criteria to a Query


Criteria are used to restrict or narrow down which records are returned in the query. The results of using criteria on a query is similar to filtering on a form.
1. In the Queries objects window, right click on qryCDMasterList 2. Choose Copy 3. Right click again and choose Paste 4. Name the new query qryCDMasterWithCriteria 5. Open the new query in Design View 6. In the Criteria row under Genre, type Bluegrass

Access will add quotation marks around all text fields Criteria must be spelled exactly as it appears in the data

7. Switch to Query Results View

Only CDs with the Bluegrass genre will appear 8. Return to Design View

114

University Technology Training Center

LESSON 8: QUERIES

9. Add criteria for Year Released as >=2000 (greater than or equal to

2000) to return CDs from 2000 and newer

Common Symbols Used for Criteria


> < >= <= =

Greater Than Less Than Greater Than or Equal To Less Than or Equal To Equal To (understood, does not have to be specified in criteria) Not Equal To

<>

10. View the results

Adding more criteria narrows down the results even more.


11. Close and Save the query

University Technology Training Center

115

LESSON 8: QUERIES

Creating a Query in Design View


CDs on Loan Query
Create a query in Design View that displays only CDs out on Loan.
1. On the Create tab, under the Other section click on Design View

2. From the Show Table dialog box add the following tables: tblMember tblMemberCD tblCD tblPerformer

3. Close the Show Table Dialog box

4. Add the following fields by dragging them into the query design grid

From tblMember:
FirstName LastName

From tblCD:
Title

From tblPerformer:
Performer

116

University Technology Training Center

LESSON 8: QUERIES

From tblMemberCD:
LoanedToID DateOut

5. View the query results

The results include ALL CDs. Add criteria to check if there is a value in DateOut in order to return only those CDs out on loan 6. Return to Design View 7. In the DateOut Criteria row type is not null . Null is equivalent to blank

or empty.

8. View the query results again

Only CDs currently on loan will be returned

University Technology Training Center

117

LESSON 8: QUERIES

Replacing the Loaned to Key with the Member Name


Lastly, we will want to replace LoanedToID with the actual Members name that has the cd out on loan.
1. Switch back to Design View 2. Using Show Table, Add tblMember to the Design View a second time

so we can link it to LoanedToID. It will be called tblMember_1 since tblMember is already in the query.
3. Link MemberID in tblMember_1 to LoanedToID in tblMemberCD

4. Delete LoanedToID from the query design grid 5. Replace it with LastName from tblMember_1 6. Add Lent To: in front of the LastName field you just added to

differentiate it from the Lender

7. View the query results

8. Close and Save the query as qryCDOnLoan

118

University Technology Training Center

LESSON 8: QUERIES

Exercise 8: Creating a Query in Design View


Member Directory
Create a query that displays all the members and all their addresses in the database.
1.

On the Create tab, under the Other section click on Query Design

2. From the show table dialog box add tblMember, tblMemberAddress, and tblAddress Type 3. Add the Name fields from tblMember 4. Add AddressType from tblAddressType 5. From tblMemberAddress add the fields from Address1 thru Email

6. Sort Ascending by the Members Last Name

University Technology Training Center

119

LESSON 8: QUERIES

7. View the query results, you should have 22 records

Notice that you have more than one record for some Members. Even though they are only in the database once, they have more than one Address in the table. When you join the tables, it finds all the matches and displays them. 8. Close and Save as qryMemberAddress

End of Exercise

120

University Technology Training Center

9
Lesson
Lesson 9

Reports
Reports have the same dynamic properties that queries do. Reports are used to format data for printing. You can also use reports to create labels. Most reports are based on queries that pull information from multiple tables. More than one report can be generated from a single query (different sorting and layout options can be used and not every field from the query has to be pulled for the report).

Creating a Report Using the Auto Report option


Master list of all CDs in the club
1. From the Object Navigation pane choose qryCDMasterList 2. From the Create tab choose Report

University Technology Training Center

121

LESSON 9: REPORTS

3. Your report will be displayed

Touch Up Report
1. Switch to Design View 2. Edit the title to read CD Master List

3. The records should be sorted by Title. From the Grouping and Totals section of the Design tab choose Group & Sort

122

University Technology Training Center

LESSON 9: REPORTS

4. Choose Add a Sort

5. Choose the Title field

6. View the report results again to see the changes

7. Close and Save the report as rptCDMasterList

University Technology Training Center

123

LESSON 9: REPORTS

Printing a report
1. Open rptCDMasterList by double clicking on it 2. Click on the Office button

3. Hover over Print and choose Print Preview to view the report first

and make and needed adjustments to the margins, paper orientation etc.

4. If you are ready to print click on Print, otherwise click on Close Print Preview

124

University Technology Training Center

LESSON 9: REPORTS

Exercise 9: Creating a Report Using Auto Report


List of CDs out on loan
1. From the Object Navigation pane choose qryCDOnLoan 2. From the Create tab choose Report

3. Your report will be displayed

Touch Up Report
1. Switch to Design View and 2. Edit the title to read CDs On Loan 3. Put spaces in the field labels as needed 4. Make the Name fields smaller to make room for the rest of the fields. 5. Close and Save the report as rptCDOnLoan End of Exercise

University Technology Training Center

125

LESSON 9: REPORTS

Creating a Report Using the Wizard


List of CDs by Genre
A report that lists all the CDs in the club, grouped by Genre so Genre shows up once and all the CDs within that Genre are indented and shown below it.

1. From the Create tab, reports section, choose Report Wizard

2. In the Tables/Queries pick list choose the qryCDMasterList query

126

University Technology Training Center

LESSON 9: REPORTS

3. Add the following fields: Genre Title Performer

4. Click Next 5. View data by tblGenre (what we want to group by) Click Next

6. No additional grouping levels needed so Click Next

University Technology Training Center

127

LESSON 9: REPORTS

7. Choose Title to sort by (within each Genre grouping) Click Next

8. Leave layout as the default, Stepped and Portrait Click Next

9. Choose the report style Access 2007 (to keep consistent style with the

rest of the database) Click Next

128

University Technology Training Center

LESSON 9: REPORTS

10. Name the report rptCDMasterbyGenre Click Finish

11. The report displays in Print Preview mode, Click on Close Print Preview to go to design view

12. Edit the title to read CD Master by Genre 13. Select the Genre field and make it wider 14. Select the Performer field and make it wider (dont go beyond the

right border of the report)

University Technology Training Center

129

LESSON 9: REPORTS

15. View the report

16. Close and Save the design changes

130

University Technology Training Center

LESSON 9: REPORTS

Exercise 10: Creating a Report Using the Wizard


List of CDs by Performer
A report that lists all of the CDs in the club, grouped by Performer so the Performer shows up once and all the CDs by that person or group are indented and shown below it. We will use the same query from the last exercise, just grouping it differently. We can use our database more efficiently by reusing queries.

1. From the Create tab, reports section, choose Report Wizard

University Technology Training Center

131

LESSON 9: REPORTS

2. In the Tables/Queries pick list choose the qryCDMasterList query

3. Add the following fields: Performer Title Genre

4. Click Next 5. View data by tblPerformer (what we want to group by) Click Next

132

University Technology Training Center

LESSON 9: REPORTS

6. No additional grouping levels needed so Click Next

7. Choose Title to sort by (within each Performer grouping) Click Next

University Technology Training Center

133

LESSON 9: REPORTS

8. Leave layout as the default, Stepped and Portrait Click Next

9. Choose the report style Access 2007 (to keep consistent style with the

rest of the database) Click Next

10. Name the report rptCDMasterbyPerformer Click Finish 11. The report displays in Print Preview mode, Click on Close Print Preview to go to design view

12. Edit the title to read CD Master by Performer

134

University Technology Training Center

LESSON 9: REPORTS

13. Select the Performer field and make it wider (dont let the fields go

beyond the right border of the report)

14. View the report

15. Close and Save the design changes

End of Exercise

University Technology Training Center

135

10
Lesson
Lesson 10

Final Touches
Menu
To further enforce not entering data into the tables and to make the database as easy to navigate as possible, you can use the Switchboard wizard to create a menu system.

Creating a Switchboard
1. On the Database tools tab, under Database tools, choose Switchboard Manager 2. The first time you run it you will be prompted to create a new

switchboard

University Technology Training Center

137

LESSON 10: FINAL TOUCHES

3. Click Yes to create a new Switchboard 4. Click Edit

5. Click New

6. Add the Text for the first Item: Enter Members 7. Choose Open Form in Add Mode in the Command line (this will only

allow some to Add a new member, they cannot view existing)


8. Choose the form name in the Form line

9. Click OK

138

University Technology Training Center

LESSON 10: FINAL TOUCHES

10. Click New to add the next menu item, this one will allow the user to

view existing members

11. Click OK 12. Repeat for the rest of the forms

University Technology Training Center

139

LESSON 10: FINAL TOUCHES

13. Create the items for the three reports. Menu items for Reports are created the same way, except you choose Open Report for the

Command

If you try to add another item at this point you will get a message. Access does limit each switchboard to 8 items, but you can have multiple switchboards, one for forms, one for reports, etc.

14. Click OK, thats all we are going to add to the switchboard for now 15. Click Close on the 2 Switchboard screens

140

University Technology Training Center

LESSON 10: FINAL TOUCHES

Display Switchboard when Database Opens


1. From the Office button choose Access options

2. Choose Current database

3.

Under Display Form choose Switchboard from the dropdown list

4. Click OK to save and close 5. You will be prompted to close and reopen the database to see the results of the change. Click OK.

University Technology Training Center

141

LESSON 10: FINAL TOUCHES

6. Close the database and Reopen to see the Switchboard

142

University Technology Training Center

LESSON 10: FINAL TOUCHES

Database Maintenance and Backups


As you work with your Access database, the file size will grow. If the file size looks out of line with the amount of data you have stored or it starts running really slowly, its might be time to compact your database. As you add, delete, import, and move data in the database, Access takes more space as it needs it. The space is not automatically relinquished; it is up to you to decide when to give it back. Think of it as defragging your hard drive. If your database ever gets corrupted by a power outage or hard drive failure, the repair part of the Compact and Repair should solve any issues you might have.

Compact and Repair Database


The frequency with which you run Compact and Repair varies on how heavily your database is used. It should be run a minimum of once a month and more often if needed. No one else should be accessing the database while Compact and Repair running. It runs fairly quickly, but the length of time will depend on the amount of data and your computer speed.
1. Under the Office menu choose Manage 2. Then choose Compact and Repair

The database will be closed and reopened when it has completed the process.

University Technology Training Center

143

LESSON 10: FINAL TOUCHES

Backing Up the Database


Backups are critical to any file but especially Access databases. There are so many things in Access that cannot be undone that backups are recommended daily, as well as before any major changes are done to the database. In Access 2003 and newer, you now have a menu option for running a backup. It will ask you where you would like to store the backup and adds a date stamp to the file name. If your Access database is stored on a server, speak with your server administrator about including the file in the nightly backups.
1. Under the Office button choose Manage 2. Then choose Back Up Database

144

University Technology Training Center

LESSON 10: FINAL TOUCHES

3. You will be prompted for a location and name, click Save when you

are ready to run the backup.

University Technology Training Center

145

A
Appendix A

Appendix

Using the Label Report Wizard


Create formatted address labels for all the members in the club.
4. Select the query qryMemberAddress in the Object Navigation Pane 5. On the Create tab, Reports section choose Labels 6. Choose Avery 5160 as the label size

7. Click Next

University Technology Training Center

147

APPENDIX A: USING THE LABEL REPORT WIZARD

8. Choose a Font and Font Size (this can always be adjusted later)

9. Click Next 10. Add fields to the Prototype Label area by selecting them from the Available Fields section.

Note:

More than one field can be placed on a line. To add to another line, click in that line, hitting Enter will take you to the next step in the wizard. Add spaces where appropriate and a comma between City and State.

148

University Technology Training Center

USING

THE

LESSON 10: LABEL REPORT WIZARD

11. Choose to sort by Last Name

12. Name the report rptMemberAddressLabels and click Finish. The

report will open in print preview mode.

University Technology Training Center

149

B
Appendix B

Appendix

Creating a Query Using Aggregate Functions


Next we will create a query using aggregate functions to calculate Count, Sum, Average, Min, and Max of the values of CDs within each genre.
13. Create a new query in Design View 14. Add tblCD and tblGenre to the query design 15. Add Genre from the tblGenre to the query grid 16. Add CDValue from tblCD to the query grid 17. From the Show/Hide section of the Design tab, choose Totals.

This will display a new line on the query grid labeled Total. The default value for each field is Group By. Group By is used to combine all like values of that field

University Technology Training Center

151

APPENDIX B: CRE ATING A QUERY USING AGGREGATE FUNCTIONS

18. We want to group by Genre so leave the Group By value in the Genre

field

If we leave Group By in the Value field as well and Preview the query, we would see the query shows each unique Value within each Genre, thats not what we are looking for

19. Change the Group By under the CDValue field to Sum using the drop

down list

20. Right click on the CDValue column in the Query grid and choose Properties

152

University Technology Training Center

CREATING

LESSON 10: QUERY USING AGGREGATE FUNCTIONS

21. Choose Currency from the Format dropdown

22. Preview the Query

The new temporary name for the CDValue column is SumOfCDValue. We are now seeing a sum of the values of all CDs within each Genre
23. Return to Design View and add the Title field from tblCD 24. Change Group By to Count in the Total row under Title

University Technology Training Center

153

APPENDIX B: CRE ATING A QUERY USING AGGREGATE FUNCTIONS

25. Preview the query

We now have a count of how many CD Titles exist under each Genre
26. Return to Design View and add the CDValue field three more times 27. Change one of each of the newly added CDValue fields to Avg, Min, and Max

28. Format each of the three new CDValue columns to Currency

Hint: you can leave the properties window open and click on another field to set its properties.
29. Preview the query results

30.

Close and Save the query as qryCDTotalsbyGenre

154

University Technology Training Center

C
Appendix C

Appendix

Exporting Query Results


31. Open qryCDTotalsbyGenre in query results view (query created in

prior appendix)
32. When the query results are on the screen, from the External Data tab, choose Excel

33. You will be prompted for the file location and format 34. Choose to Export with formatting and to Open the destination file

35. Click ok and an Excel document will open showing the query data

University Technology Training Center

155

APPENDIX C: EXPORTING QUERY RESULTS

36. You can then add totals or other Excel functions

You can also choose to save as Text, html, xml and other options.
37. When you return to Access you will see a screen asking if you want to

save your export steps

156

University Technology Training Center

LESSON 10: EXPORTING QUERY RESULTS

If this is something you will do on a regular basis and you want to automate it, click on the box. You will be given more options:

38. We will not be saving this export so we can just click Close

University Technology Training Center

157

D
Appendix D

Appendix

Creating a Member Address Report Using the Wizard


You will be creating a report listing all of the Members along with their address(es). You want to group by the Member and show their address indented underneath.

39. From the Create tab, reports section, choose Report Wizard

40. In the Tables/Queries pick list, choose the qryMemberAddress query

University Technology Training Center

159

APPENDIX D: CREATING A MEMBER ADDRESS REPORT USING

THE

WIZARD

41. Add the following fields, in order LastName FirstName AddressType Address1 Address2 City State Zip

42. Click Next 43. View data by tblMember , click Next 44. No additional grouping, click Next 45. Sort by AddressType, click Next 46. Set layout as Stepped and Landscape, click Next

47. Choose the report style Access 2007, click Next 48. Name the report rptMemberAddress , click Finish 49. Close Print Preview

160

University Technology Training Center

CREATING

MEMBER ADDRESS REPORT USING

THE

LESSON 10: WIZARD

50. Edit the report title and add spaces in the field labels, switch between

design and report view as needed Change the Title at the top of the report to Member Address
List

Edit the Names, Address Type, and Address labels (not field names) to add spaces between the words Shrink or expand fields as needed so data is not getting cut off (as much as possible)(dont let the fields go beyond the right border)

51. Close the report and Save the changes made

University Technology Training Center

161

Appendix

E
Appendix E

Exporting a Report
Reports in Access can easily be exported to Word for use as an email attachment.
52. In the Reports objects navigation pane, double click on rptCDMasterbyPerformer 53. Go to Print Preview using the Office button 54. In the Data section click on Word

You will be prompted for the file name and location to save the document. The report results will be exported to Word as an *.rtf (rich text format) file.

University Technology Training Center

163

APPENDIX E: EXPORTING A REPORT

55. Click the option to open the destination file and Word will launch

and display the document. Notice that some formatting will not show up (e.g., lines and other graphical elements.) because the rtf format can only display text.

164

University Technology Training Center

You might also like