Você está na página 1de 12

BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 1 of 12

MS ACCESS 2003

DATA ACCESS PAGES

Data Access Pages

What is a Data Access Page?


A data access page (DAP) is a special kind of Web page created by Microsoft Access. It includes
database characteristics, so that when someone views the page in Microsoft Internet Explorer, they are
able to view the database and change data in it.
Data access pages are used so that multiple users can share a database across a network.
Important:
• In the business world a data access page is put on a network server so that various users can view
and change the database. Normally, you would not want your database open to changes by
anyone in the world, so your data access pages would be put on an intranet, not the Internet.
• Because the data access pages that you create in this exercise will be stored on your local computer
rather than being available on a network server, only you on your local computer will be able to
use them.
• As with several other advanced features of Microsoft Office in this course, this section gives you just
an introduction to the topic.

Ex. 1 Create a Data Access Page using the Page Wizard


In this exercise you will create a simple data entry page. (There are 2 other types of data access pages,
outlined at the end of this section.)

1. Open the Addresses.mdb database (which you created earlier in the Data Validity unit).
2. Click on Pages.

Note: The top of the window reads Access 2000 file format. This is the default file format for
Access 2003, so that the database can be shared with Access 2000 and 97 users.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 1 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 2 of 12

MS ACCESS 2003

DATA ACCESS PAGES

3. Click on Pages.
4. Double-click on Create data access page by using wizard. The first Page Wizard window opens.

5. The tblAddresses table Is showing in the Tables/Queries box. (The drop-down button would
allow you to select a different table or a query, if available; you would select those containing the
fields you want on your DAP.)

6. Select all the fields except tbIAddressesID and SexAge. (Hint: use the >> button to move them
all, then move the unwanted fields back).
7. Click on Next.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 2 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 3 of 12

MS ACCESS 2003

DATA ACCESS PAGES

8. Do not add grouping level.


9. Click on Next.
10. Sort by Last Name, then First Name.

11. Click on Next.


12. Name the page InputAddresses.
13. Select Modify the page's design.
14. Select Do you want to apply a theme to your page?

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 3 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 4 of 12

MS ACCESS 2003

DATA ACCESS PAGES

15. Click on Finish. A window opens allowing you to choose a theme.

16. Scroll through your choice, and select any theme you like (some simples ones are Arctic, Axis,
Compass, Journal, Profile).
17. Click OK.
18. Click in the title area.
19. Type in My Address Book.
20. Click in the body area below the title.
21. Type in Use navigation buttons on bottom of screen to move through address list .

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 4 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 5 of 12

MS ACCESS 2003

DATA ACCESS PAGES

22. Save the page as InputAddresses.


23. Close the page.
24. Close the database.

Ex. 2 Use Internet Explorer to view and change a database


1. In Internet Explorer (version 5 or later) open lnputAddresses.htm (File / Open / Browse).
Note: A data access page is the only Access object stored external to the .mdb database file.
2. See what happens when you click on the navigation buttons below the fields (they look like the
symbols on a VCR) for Forward, Back, Last Record, First Record, Sort, Filter.
0.001"Note: Do NOT click on the New Record button yet! (See next step.)
3. Try the Sort Ascending and Sort Descending buttons to see that they work as you expect them to.
4. Go to the last record.
New
a. Click on the New Record button. Record
b. Add a new record as follows (Hint: use Tab to move through fields):
i. LastName – Yeah
ii. FirstName –Yorick
iii. Address - 888 88th St.
iv. Province – PQ
v. Email Address - yyeah@hotmail.com
vi. Home Phone - (416) 888-8888
vii. Postal Code - M8M 8M8.
Save
5. Click on the Save Record button. Record
6. Try the Undo Edit button by creating a new record then undoing it. (Hint: to save time, key in only
a few random characters for each field.)
7. Try the Help button.
8. Notice the bar at the bottom of the screen showing the number of the current record and the total
number of records.

9. Click in the Province field.


10. Click on the Filter by Selection button. Notice that filtering has changed the total number of
records.
11. View the next record.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 5 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 6 of 12

MS ACCESS 2003

DATA ACCESS PAGES

12. Click on the Toggle Filter button to undo the filtering. Notice that the total number of records has
been restored to include the entire database.
13. Click on the Save Record button.
14. Close Internet Explorer.
15. Open the Addresses.mdb database. See if the new record has been successfully added to
tbIAddresses.
16. Save the changes to the table.
17. Close the database.

Ex. 3 Add a field to a data access page


1. Open the Addresses.mdb database.
2. In the main database window select Pages.
3. Select InputAddresses.
4. Click on Design.

5. Click on an empty area of the form – the area to the right of the field names and field boxes - so
that the sizing handles of the form appear (small white squares on the edges of the form).

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 6 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 7 of 12

MS ACCESS 2003

DATA ACCESS PAGES

6. Use the sizing handles to make room at the bottom of the form, below the last field.

7. Click on the Field List button on the standard toolbar (it looks like a simple rectangular document
next to the Toolbox button).

8. In the Field List task pane at the right side of the screen, to show all your tables and the fields in
tblAddresses, click on the plsu sign next to tables and the plsu sign next to tblAddresses.

9. Select the SexAge field.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 7 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 8 of 12

MS ACCESS 2003

DATA ACCESS PAGES

10. Click on the Add to page button at the top of the task pane.

11. Click on the SexAge input box. A new fieldname and input box are added to the DAP.
When you put your cursor over SexAge, it changes to a black hand.

12. Click on the SexAge fieldname and input box. Drag below the other fields.
Note: If you inadvertently select only one of the fieldname or the input box, re-select by holding
the Shift key down while clicking on one then the other.
13. Save the page.
14. Close the database.
15. Test your results in Internet Explorer, as you did earlier in Ex. 2.

Ex. 4 Data Access Pages created quickly with AutoPage


A very quick way to create a data access page is to use
AutoPage. The results of AutoPage are fast but plain
and simple, as you will see. It is used to create a simple
interface when a professional appearance is not
important. Try it as follows:
a) In the main database window of the Addresses
database select Pages.
b) Click on the New button.
c) Click on AutoPage.
d) Follow the prompts to create a data access
page.
e) When you are finished, do NOT save the page.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 8 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 9 of 12

MS ACCESS 2003

DATA ACCESS PAGES

Enrichment
The section below is for students who have finished their work before the rest of the class. It will give you
a higher level of expertise with Microsoft Word 2003.
This material will not appear on tests.

Ex. 5 Add Features to a Data Access Page


A Note on Controls. You can add text, labels and many kinds of controls to a data access page.
Controls on a data access page are the same as controls on a form or report. A control is a graphical
object that you place on a form or report to display data, perform an action or enhance the appearance of
the form or report. Examples of controls are boxes that show field values, field labels, lines, rectangles,
command buttons, text input boxes and check boxes. There are 3 types of controls:
• A bound control is "bound" (i.e. tied) to a field in the database table, where it gets its value. As the
data in the table changes, the value of the bound control changes with it.
• An unbound control has no tie to the underlying table data and retains the value you enter.
• A calculated control is an expression containing field values combined with functions and
operators to calculate a result. The value of a calculated control changes as the values in the
underlying fields change. (In this course we will not be adding calculated controls to data access
pages.)

1. Open the Addresses database.


2. In the main database window select Pages.
3. Select InputAddresses.

4. Click on Design.
5. Make sure that the Toolbox is showing.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 9 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 10 of 12

MS ACCESS 2003

DATA ACCESS PAGES

If it’s not showing, select View / Toolbox.


6. Move your cursor over the icons in the Toolbox and wait for the yellow tag to appear identifying
each one. Then use the Toolbox to add the following in 12 point Verdana font below the SexAge
field:
• a label with the words This is a label.
• a text box with the words Input text here.
• an unbound hyperlink to www.tdsb.on.ca
• scrolling text with the message A data access page works only with Internet Explorer 5 or
higher, but adjust the width of the box so that only the first 7 words show.
Notice that the Toolbox allows you to add many types of controls, such as a chart, an image, an
Excel spreadsheet, a line, a rectangle, etc.
7. Select Format / Background / Color.
8. Add a pale blue background color.
9. Click on SexAge.
10. Press Delete.
11. Using the Toolbox, replace it with a drop-down list with the 4 possible values for SexAge (Teen
Female, etc.).
12. Save the page.
13. Close the database.
14. View the page in Internet Explorer.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 10 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 11 of 12

MS ACCESS 2003

DATA ACCESS PAGES

Ex. 6 Data Access Pages created from an existing HTML document


Access can also turn an existing HTML page into a data access page. Read the following to make
yourself aware of the procedures. (The necessary software has not been fully installed on many of our
computers to enable you to test the procedures.)
1. Go to http://schools.tdsb.on.ca/jarvisci/externalpage.html.
2. Select View/Source.
3. Copy the text.
4. Open Notepad.
5. Paste the text into Notepad.
6. Save on your home drive as externalpage.html.
7. Close the browser.
8. In the main database window of the Addresses database select Pages.
9. Click on the New button at the top of the window.
10. Click on Existing Web page.

11. The Locate Web Page dialog box opens.


12. Browse to find externalpage.html.
13. Open externalpage.html.
For now, this is just an HTML document, not yet a data
access page.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 11 of 10
BTA3O1 – Productivity Software – Unit 3: Database – Part 3: Data Validity– Page 12 of 12

MS ACCESS 2003

DATA ACCESS PAGES

14. Place your cursor where you want the first field to appear, below the line at the bottom of the
page.
15. Open the Field List box as in Ex. 3, Step 7 above.
16. Add a field to the page from the Field List box (it does not matter which kind of field you choose).
17. Before selecting the next field, click to place your cursor where you want the next field to appear.
18. Add several more fields to the page from the Field List box.
19. Save the page.
20. Test the data access page in Internet Explorer as in earlier exercises.

BTA3O1 Information and Communication Technology: The Digital Environment- Productivity Software
Unit 3: Database – Part 3: Data Validity– Page 12 of 10

Você também pode gostar