`
`
`
`
`
`Merrill Communications LLC
`d/b/a Merrill Corporation
`Exhibit 1005 pt 1
`
`
`
`Alan Simpson
`Elizabeth Olson
`
`The Most Comprehensive Guide by
`Best-Selling Access Experts—with
`Coverage of New Internet Features
`
`Access 9/
`
`BMTOryceeicMeCleCy
`
`ersyet
`
`PeORR CC
`
`
`
`
`
`
`
` MASTERING
`
`ACCES J/
`
`FOURTH EDITION
`
`
`
`
`
`
`
`®
`
`FOURTH EDITION
`
`Alan Simpson
`Elizabeth Olson
`
`San Francisco • Paris • DUsseldorf • Soest
`
`
`
`Library of Congress Card Number: 96-71646
`
`ISBN: 0-7821-1924-7
`
`Manufactured in the United States of America
`
`20 19 18 17 16 15 14 13 12 II
`
`Associate Publisher: Amy Romanoff
`Acquisitions Manager: Kristine Plachy
`Acquisitions & Developmental Editor: Melanie Spiller
`Reviser: Celeste Robinson
`Editor: June Waldman
`Project Editors: Brenda Frink and Kimberley Askcw-Qasem
`Technical Editor: Rae! Dornfest
`Book Designers: Catalin Dulfu and Patrick Dint! no
`Graphic Illustrator: Heather Lewis
`Desktop Publisher: Susan Glinert Stevens
`Production Coordinator: Robin Kibby
`Proofreaders: Grey Magauran and Michael Tom
`Indexer: Ted Laux
`Cover Designer: Design Site
`Cover Photographer: Mark Johann
`
`Screen reproductions produced with Collage Complete.
`
`Collage Complete is a trademark of Inner Media Inc.
`
`SYBEX Is a registered trademark of SYBEX Inc.
`Mastering Is a trademark of SYBEX Inc.
`
`TRADEMARKS: SYBEX has attempted throughout this book to
`distinguish proprietary trademarks from descriptive terms by fol(cid:173)
`lowing the capitalization style used by the manufacturer.
`
`The author and publisher have made their best efforts to prepare
`this book, and the content is based upon final release software
`whenever possible. Portions of the manuscript may be based
`upon pre-release versions supplied by software manufacturer(s).
`The author and the publisher make no representaUon or warran(cid:173)
`ties of any kind with regard to the completeness or accuracy of
`the contents herein and accept no liability of any kind including
`but not limited to performance, merchantabillty, fitness for any
`particular purpose, or any losses or damages of any kind caused
`or alleged to be caused directly or indirectly from this book.
`
`The first two editions of this book were published under the title
`Understaudi11g Microsoft Access.
`
`~lrst edition copyright ©1993 SYBEX Inc.
`
`Second edition copyright ©1994 SYBEX Inc.
`
`Third edition copyright ©1996 SYBEX Inc.
`
`Copyright ©1997 SYBEX Inc., liS I Marina Village Parkway,
`Alameda, CA 94501. World rights reserved. No part of this publi(cid:173)
`cation may be stored in a retrieval system, transmitted, or repro(cid:173)
`duced in any way, including but not limited to photocopy,
`photograph, magnetic or other record, without the prior agree(cid:173)
`ment and written permission of the publisher.
`
`
`
`Disclaimer
`SYBEX makes no warranty or representation, either expressed or
`implied, with respect to this media or its contents, its quality,
`performance, merchantability, or fitness for a particular purpose.
`In no event will SYBEX, its distributors, or dealers be liable to
`you or any other party for direct, jndirect, special, Incidental,
`consequential, or other damages arising out of the use of or
`inability to use the media or its contents even if advised of the
`possibility of such damage.
`The exclusion of implied warranties is not permitted by some
`states. Therefore, the above exclusion may not apply to you.
`This warranty provides you with specific legal rights; there may
`be other rights that you may have that vary from state to state.
`The pricing of the book with the Software by SYBEX reflects the
`allocation of risk and limitations on liability contained In this
`agreement of Terms and Conditions.
`
`Shareware Distribution
`This Software media may contain various programs that are dis(cid:173)
`tributed as shareware. Copyright laws apply to both shareware
`and ordinary commercial software, and the copyright Owner(s)
`retains all rights. if you try a shareware program and continue
`using it, you are expected to register it. Individual programs dif(cid:173)
`fer on details of trial periods, registration, and payment. Please
`observe the requirements stated in appropriate flies.
`
`Copy Protection
`None of the files on the disk is copy-protected. However, in all
`cases, reselling or redistributing these files without authorization
`is expressly forbidden except as specifically provided for by the
`Owner(s) therein.
`
`Software License Agreement: Terms and Conditions
`The media accompanying this book contains software ("the Soft(cid:173)
`ware") to be used in connection with the book. SYBEX hereby
`grants to you a license to use the Software, subject to the terms
`that follow. Your purchase, acceptance, or use of the Software will
`constitute your acceptance of such terms.
`The Software compilation is the property of SYBEX unless other(cid:173)
`wise indicated and is protected by copyright to SYBEX or other
`copyright owner(s) as indicated in the media files (the "Owner(s)").
`You are hereby granted a single-user license to use the Software for
`your personal, noncommercial use only. You may not reproduce,
`sell, distribute, pub1ish, circulate, or commercially exploit the Soft(cid:173)
`ware, or any portion thereof, without the written consent of SYBEX
`and the specific copyright owner(s) of any component software
`Included on this media.
`
`Software Support
`Components of the supplemental software and any offers associ(cid:173)
`ated with them may be supported by the specific Owner(s) of
`that material but they are not supported by SYBEX . Information
`regarding any available support may be obtained from the
`Owner(s) using the information provided in the appropriate
`read .me files or listed elsewhere on the media.
`Should the manufacturer(s) or other Owner(s) cease to offer sup(cid:173)
`port or decline to honor any offer, SYDEX bears no responsibility.
`This notice concerning support for the Software Is provided for
`your Information only. SYBEX is not the agent or principal of the
`Owner(s), and SYBEX is in no way responsible for providing any
`support for the Software, nor is it liable or responsible for any sup(cid:173)
`port provided, or not provided, by the Owner(s).
`
`Warranty
`SYBEX warrants the enclosed media to be free of physical defects
`for a period of ninety (90) days after purchase. The Software is
`not available from SYBEX in any other form or media than that
`enclosed herein. If you discover a defect in the media during this
`warranty period, you may obtain a replacement of Identical for(cid:173)
`mat at no charge by sending the defective media, postage pre(cid:173)
`paid, with proof of purchase to:
`
`SYBEX Inc.
`Customer Service Department
`1151 Marina Village Parkway
`Alameda, CA 94501
`(510) 523-8233
`Fax: (510) 523-2373
`e-mail: info@sybex.com
`
`After the 90-day period, you can obtain replacement media of
`identical format by sending us the defective disk, proof of pur(cid:173)
`chase, and a check or money order for $10, payable to SYBEX .
`
`
`
`
`
`To Susan, Ashley, and
`Alec, as always
`-Alan Simpson
`
`To Keith, for encourag(cid:173)
`ing me and keeping
`me sane
`-Elizabeth Olson
`
`
`
`
`
`ACHNOWLEOGEMENTS
`
`his book wa a massive undertak(cid:173)
`ing. Many thanks to everyon
`n
`the team wbo stuck with it despite
`the brutal schedule. The authors would like to thank Reviser Celeste Robinson who
`carefully updated this edition of the book, writing at a breakneck pace.
`Many thanks to Sybex's editorial and production teams for their much-appreciated
`support. Developmental Editor Melanie Spiller got us started on the right foot. Project
`Editor Brenda Frink kept things moving smoothly, Editor June Waldman edited quickly
`and thoroughly, and Project Editor Kim Askew-Qasem jumped in at the last minute to
`get the book out on time. We also want to extend our gratitude to Desktop Publisher
`Susan Glinert Stevens, Production Coordinator Robin Kibby, Indexer Ted Laux, and to
`the many others on the Sybex team who made this book possible. A huge amount of
`thanks go to Technical Editor Rael Dornfest for his meticulous review of the book's
`new sections.
`The authors wish to thank Dr. Forrest Boulette for his many contributions to Parts III,
`IV, and V of this book's third edition. Way to go Forrest! Writing credits also go to Mike
`Gunderloy, the technical editor who put on an additional hat for us by writing the third
`edition's Chapter 18.
`We're tremendously grateful to the Microsoft support team who kept us supplied
`with the latest test software as we raced to meet our deadlines.
`And last, but not least, a million thanks to our families-Ashley, Susan, and Alec
`Simpson and Keith Olson-for their patience and support through so many long
`bouts of frenzied book writing.
`
`
`
`CONTENTS RT R GLRNCE
`
`Introduction
`
`XXXVII
`
`PART I
`
`AN OVERVIEW OF ACCESS
`
`Ch1 Getting Started and Getting Around
`Ch2 Understanding Databases
`Ch3
`Access in an Evening
`About Access 9 7, Office 9 7, Windows 95, and the Internet
`Ch4
`
`PART II
`
`CREATING A DATABASE
`
`Ch5 Creating a Database and Application
`Ch6 Creating Access Tables
`Ch7
`Linking, Importing, and Exporting Data
`ChB Adding, Editing, and Viewing Data
`Ch9 Sorting, Searching, Filtering, and Printing
`Ch10 Querying Your Tables
`Ch11 Creating Forms with Form Wizards
`Ch12 Creating Reports with Report Wizards
`Ch13 Creating Custom Forms and Reports
`-
`Ch14 Creating Charts and PivotTables
`
`I
`
`3
`37
`49
`101
`
`128
`
`131
`153
`207
`255
`307
`357
`417
`445
`475
`- -
`565
`
`
`
`CONTENTS AT A GLANCE
`
`PART Ill
`
`DATABASE TUNING AND ADMINISTRATION
`
`Ch75 Personalizing Access
`Ch76 Speeding Up Your Database
`Ch77 Administering Your Database
`Ch78 Networking and Security
`
`PART IV
`
`BUILDING A CUSTOM APPLICATION
`
`Ch79 Creating a Custom Application
`Ch20 Using Macros to Create Custom Actions
`Ch21 Creating Custom Switchboards
`Ch22 Creating Custom Dialog Boxes
`Ch23 Creating Custom Too/bars
`Ch24 Creating Custom Menus
`
`PARTV
`
`REFINING A CUSTOM APPLICATION
`
`Introducing Visual Basic for Applications
`Ch25
`Ch26 Creating Custom Error Messages
`Ch27 ln~eracting with Other Programs
`Ch28 Pulling It All Together
`
`612
`675
`645
`
`659
`679
`
`712
`
`775
`73 7
`765
`793
`
`877
`837
`
`850
`
`853
`869
`885
`897
`
`
`
`CONTENTS RT R GLRNCE
`
`Introduction
`
`XXXVII
`
`3
`37
`
`49
`
`707
`
`128
`
`737
`
`753
`207
`
`255
`
`307
`
`357
`
`477
`445
`475 - -
`565
`
`PART I
`
`AN OVERVIEW OF ACCESS
`
`Ch7 Getting Started and Getting Around
`Ch2 Understanding Databases
`Ch3
`Access in an Evening
`Ch4 About Access 97, Office 97, Windows 95, and the Internet
`
`PART II
`
`CREATING A DATABASE
`
`Ch5 Creating a Database and Application
`Ch6 Creating Access Tables
`Ch7
`
`Linking, Importing, and Exporting Data
`ChB Adding, Editing, and Viewing Data
`h9 Sorting, Searching, Filtering, and Printing
`Ch70 Querying Your Tables
`Ch7 7 Creating Forms with Form Wizards
`Ch72 Creating Reports with Report Wizards
`Ch73 Creating Custom Forms and Reports
`Ch74 Creating Charts and PivotTables
`
`-C
`
`
`
`.....
`
`CONTENTS AT A GLANCE
`
`PART Ill
`
`DATABASE TUNING AND ADMINISTRATION
`
`Ch15 Personalizing Access
`Ch76 Speeding Up Your Database
`Ch17 Administering Your Database
`Ch18 Networking and Security
`
`PART IV
`
`BUILDING A CUSTOM APPLICATION
`
`Ch79 Creating a Custom Application
`Ch20 Using Macros to Create Custom Actions
`Ch21 Creating Custom Switchboards
`Ch22 Creating Custom Dialog Boxes
`Ch23 Creating Custom Too/bars
`Ch24 Creating Custom Menus
`
`PARTV
`
`REFINING A CUSTOM APPLICATION
`
`Introducing Visual Basic for Applications
`Ch25
`Ch26 Creating Custom Error Messages
`Interacting with Other Programs
`Ch27
`Ch28 Pulling It All Together
`
`612
`
`615
`645
`659
`679
`
`712
`
`715
`737
`765
`793
`817
`
`837
`
`850
`
`853
`869
`885
`897
`
`
`
`I CONTENTS AT A GLANCE
`
`APPENDICES
`Installing Microsoft Access
`A
`About the CD-ROM
`8
`c
`Installing and Using Fulfill 95
`
`REFERENCE
`MASTER'S REFERENCE
`
`GLOSSARY
`
`Index
`
`•
`
`973
`925
`947
`
`977
`
`1071
`
`1091
`
`
`
`T ROLE· OF CONTENTS
`
`Introduction
`
`XXXVII
`
`PART I • AN OVERVIEW OF ACCESS
`
`0
`
`0
`
`0
`
`0
`
`0
`
`•
`
`0
`
`0
`
`•
`
`0
`
`0
`
`0
`
`•
`
`0
`
`0
`
`0
`
`0
`
`0 • • 0
`
`0
`
`0
`
`0
`
`0
`
`0
`
`0 • • 0
`
`•
`
`0
`
`•
`
`0
`
`•
`
`0 • • • 0 • • • • 0
`
`Ch 1 Getting Started and Getting Around
`3
`• 6
`Starting Access 97 0
`Opening an Existing Database 0 • • 0 • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • 8
`Opening the Sample Northwind Database .......................... 1 3
`What Is a Database, Anyway? .... 0 • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • 15
`Working in the Database Window .................................. 1 7
`Closing an Object ......... 0
`• • • • • • • • • • • 0 • • • • • • • • • • • • • • • 1 7
`Uncovering a Hidden Database Window .. ..... .............. ..... 0
`• 18
`Changing Your View of Database Objects ....... .................. .. 18
`Managing Database Objects ................................ . . .. .. 18
`Using the Toolbars and Menu Bar ............... . .. .... ..... ...... .. 21
`Viewing Toolbars, ScreenTips, and the Status Bar ....... 0 • • • • • • • • • • • • • 23
`Positioning the Toolbar or Menu Bar ............... 0
`• • • • • • • • • • • • • 24
`Opening Shortcut Menus .......................... 0
`0 • • • • • • • • • • • • • 25
`Closing a Database ... ................... ... . 0
`• • • • • • • • • • • • • • • • 26
`Getting Help .................................................. 26
`Summary of Self-Help Techniques .. . ... .... .. .. ........ . . ..... .... 27
`Using the Help System and This Book ...... ..................... ... 28
`Looking Up Information ...... ............... .. ........... .. .. .. 28
`Help with Whatever You're Doing ..... ..... ...... ... .. ........... . 30
`Searching Help ............................................... 31
`Asking the Office Assistant ...... . .. 0
`• 31
`Asking "What Is This Thing?" ............................... .... . 33
`
`0
`
`0 • • • • 0
`
`0
`
`•
`
`0
`
`0
`
`0
`
`0
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`•
`
`
`
`XIV
`
`TABLE OF CONTENTS
`
`•
`
`Version Number, System Information, Technical Support ............... 33
`Getting Out of Help .. .. . ........ .... ... .. . ..... ... ... . . ....... 33
`Exiting Microsoft Access 97 .......... . . ........................... 34
`Where to Go from Here .. ... . . . ................ ... ....... . ... .... 34
`
`Ch2 Understanding Databases
`37
`Why Store Data? .............. ...... . . . . ... .. .................. 39
`Flexibility Is the Goal ........... ......... .. ................. . .... 40
`You Use Tables to Store Data .. ....... . ..... ......... ..... ......... 41
`Terminology Time ............... ........ .... ............... . ... 42
`The More Fields, the Better .. . . . . . . ... . .......................... . 43
`Why Use Multiple Tables? .......................... . .............. 43
`When to Use One Table ............. . ................. . . . . ... . . 44
`. . ....................... . ..... 44
`When to Use More Than One Table
`The One-to-Many Relationship ..... . ............... ...... . ..... .... 45
`The Primary Key Field .............. .......... . ................• 46
`It's Easier Than It Looks .... ...... .. .... ............... . .. ... .... 46
`Where to Go from Here ...... ............. ...... .. ..... . ......... 46
`
`Ch3 Access in an Evening
`49
`Before You Start These Lessons ................................. ... . 52
`Lesson 1: Creating a Database and Tables Automatically ..... . ... ........ 52
`Creating an Instant Database ................ . . . ............. . .. . 52
`Understanding the Wizards . .............. ........ .............. . 53
`Choosing Optional Fields for Your Tables ............. ...... ..... ... 54
`Including Sample Data ............................. ......... .. . 55
`Choosing a Style for Forms ........................... ... ... ... .. 55
`Choosing a Style for Printed Reports .................. . . . ....... .. . 55
`Choosing a Database Title and Adding a Picture ......... ............. 57
`Finishing Up ........ . . • . . . ......... . .. . ...................... 58
`At Your Leisure ...... .................. . ......... .. ..... . ... .. 59
`. .. ... ... . . ........................... ........ . 59
`Taking a Break
`Returning from a Break . . . .... ......... . ........ .... .. .. .... .... 60
`
`
`
`•
`
`TABLE OF CONTENTS
`
`XV
`
`Lesson 2: Exploring the Address Book Lessons Database ....... ........... 61
`Exploring the Address Book Form .................. ............... 61
`Exploring the Address Book Reports ................ ..... . ..... .... 62
`Other Buttons on the Address Book Main Switchboard .. .... .. .. .. ... .. 63
`Lesson 3: Creating and Customizing a Form ............ ... . ..... ... ... 63
`Modifying and Saving the Form Design ........ ..... .. .... . ........ 64
`Preventing the Cursor from Landing in a Field
`.. ..................... 68
`Closing and Saving the Form ............................. . ...... 68
`At Your Leisure .................................... ...... ..... 69
`Lesson 4: Adding, Editing, Sorting, and Searching ... . ....... ..... ...... 69
`Opening the Form ........................ .. .... . .. .. .... ..... 69
`Making Changes and Corrections .................. .... ..... ...... 71
`Don't Save Each Record ........... . ..... . . . . ... ... . ...... . . . . .. 74
`Sorting and Filtering ....................... ....... .. .... . ..... . 74
`Finding a Record .......................... .......... .......... 75
`Remember: Computers Are Dumb! .............. .................. 75
`Closing the Form or Datasheet ..... . . . ... . . . ......... ........ .... 76
`At Your Leisure ....................... ...... .... .............. 76
`Lesson 5: Creating and Printing Reports ......... . .................... 76
`Preparing Mailing Labels ................ ....... . ... ....... ..... . 76
`Closing and Saving the Report ........... . . .................. . .. . 78
`Don't Reinvent the Wheel! .............. ... . ...... ........ ..... . 79
`Previewing and Printing a Report ......... ....... .. . .... ... . ...... 79
`At Your Leisure ........................ ....... . .............. . 80
`Lesson 6: Using Queries .. . . . . . . ......... ... .. ........ . . ......... . 80
`Creating a Query ................... ............. .. .......... . 81
`Choosing Fields to View ............. ...................... . .... 81
`Choosing Records to View
`. . ......... ..... . ..... . ........... . .. . 82
`Choosing the Sort Order .... ...... . ... . . . ....... ... . . ... . . . . . ... 84
`Running the Query ...... .... .. ............................. . . . 85
`Changing the Query ...... . . . . . . ......... ..................... . 85
`Saving and Reusing the Query ....................... ........... . 86
`At Your Leisure ............. .......................... ....... . 87
`
`
`
`XVI
`
`TABLE OF CONTENTS
`
`Lesson 7: Customizing an Application .. . . . . . . . .. . ..... . . ..... ...... . 87
`Adding a Hyperlink to a Form ...... . ........ ... . ........... ... .. . 87
`Adding Command Buttons to a Form ... ....... . . . ... ..... ......... 88
`Creating the Button for Mailing Labels ..... . .. ..................... 90
`Creating the Query Button ....... . . . .... ... . . . . . ... . . ... . . ... . . . 90
`Creating the Close Button .... . ......... . ... .... . ... .. . .... .. .. . . 91
`Adding Visual Basic Code to a Form .... . ... .. .. . .. . ............... 91
`Customizing the Switchboard Form .. ... ... . ........... . .... . .. . .. 93
`Putting It All Together with Startup Commands . ........ . . . .... . .... . 96
`Testing the Application . .... ......... . . ...... . . . . . . . . . . . . . ... . .. 97
`At Your Leisure ....... . .......... . .... .. .. ... . ............. . . . 98
`Where to Go from Here .... .. . .. . .. .. . ........ . . . .. . . ... . . . . ... .. 98
`
`Ch4 About Access 97, Office 97, Windows 95,
`101
`and the Internet
`Making the Most of Windows 95 and Access 97 .. .. ............. . .... . 103
`Making the Most of Microsoft Office and Access .... . . ........... . .... 1 07
`The Microsoft Office Shortcut Bar ... .... .. ... .. . . ... ... . ... . . ... . 107
`Common Bars . ... .. ... ... .. .. . . . . .. . . ...... . .... . . ..... . .. .. 1 09
`Common Dialog Boxes .. ............... . ......... ..... . .... . . . 11 0
`Common Office Tools ... .. . . . ... .. .. ... ...... ... ...... . ... .. .. 11 0
`Tapping the Microsoft Knowledge Base and More ..... ...... .. . . .. .. 113
`Sharing Access Information with Other Office Programs . . .... . . . . . . .. .. . 115
`Using Import and Export .......... . ... .... . .. . ............ .... . 115
`Using OLE . ..... .... ..... . .................. ............ . ... 116
`. . .. . . . . . . . . . ... . . . . ... . . . . 121
`Using Access Data from Microsoft Excel
`Using Access Data from Microsoft Word .... . ..... . . .. . ....... ..... 124
`Sharing Access Information via the Internet . . .. . . .. . . . . . .. .. . . . . . . . . . 125
`Importing and Exporting HTML ... . ..... . ...... .... ... . . ........ 126
`Using the Publish to the Web Wizard .. . .. . . .. .. . ........... . ... . . 126
`For Programmers and Techies Only . . . . . . ... .. .. ................... 126
`About Visual Basic for Applications (VBA) .. . . . ... . ...... .. ......... 127
`
`
`
`..
`
`TABLE OF CONTENTS
`
`XVII
`
`About OLE Automation ................................... . .. .. 127
`Where to Go from Here . ............ . ......................... .. 127
`
`PART II • CREATING A DATABASE
`
`131
`Ch5 Creating a Database and Application
`------------------------
`Getting Started
`. . .... . .... .. .. ................................ 1 34
`Creating a Blank Database ... .. . . . ................. . ... . .. . ..... . 1 35
`Using the File New Database Dialog Box ... ................ . ....... 137
`Creating a Database with the Database Wizard ........ . .............. 1 38
`About the Sample Databases ..... ....... . ............... . ....... . 142
`Changing the Database Properties ..... ... . .... . ... . .. . ...... . . . ... 149
`Where to Go from Here . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 50
`
`153
`Ch6 Creating Access Tables
`Creating the Database .. ... . .. . ... . . ........... · ................. 155
`Using the Table Wizard to Create Tables ... . .. ....... . ............... 156
`Planning a Table from Scratch ......... ....... . .. . .... .. .. . .... .. . 160
`Do Not Include Calculated Fields
`. . ...... .... . ................... 160
`Creating a Table without Using a Wizard .... ........................ 160
`Defining a Table's Fields
`. ....... ...................... . ........ 162
`Choosing Appropriate Data Types ........ ..... . . . ... . ... .. ....... 162
`Defining Field Properties . . .... .............................. . . . 164
`Setting a Primary Key . ........................................ 167
`Defining Indexes ...... ............................... . .... .. . 168
`Saving a Table Structure ... . .......... .. .. ..................... 1 70
`Opening a Table .. ... . ..................... ......... . ... . . . .... 1 71
`Switching between Design and Datasheet Views ....... . ..... .. . ..... 1 71
`Why Two Views? . .. ... ... .. ........... . . ............. ........ 172
`Modifying the Table Structure .. . . ............ ............ . . . . .... 1 74
`Selecting Rows in Design View . . .... .... . .. ............. . ... . ... 174
`Saving Table Structure Changes . .... . ... .... ..... . ...... ... . . .. . 1 75
`
`
`
`X
`
`II
`
`TABLE OF CONTENTS
`
`Moving, Copying, Deleting, Renaming Entire Tables ...... ..... ..... . . 1 76
`Changing Properties of an Entire Table or Object .............. .. . ... 1 76
`More Database Window Tricks ............. ... ....... ........... 1 76
`Tables in the Order Entry Database .... .. ...... ... . ... .... ... .. ... .. 1 76
`The Customers Table .............................. . ..... ..... 1 77
`The Products Table ......... .................. . .......... ..... 1 79
`The Orders Table ....... ........ . . . . ..... . .............. ..... 180
`The Order Details Table ......................... . ..... . . ...... 181
`The Employees Table .... ......... . . ........ ..... . . ... ... ..... 182
`The Payments Table ...... . . . ... .............................. 182
`Other Tables in Order Entry ....................... .. . .......... 183
`About Lookup Fields ...... ... ........... .................. . ... . . 184
`Use a Query When...
`. .. .. .......... . .. . . . . . . . . ... ... . . .. .. ... 185
`Use a Table When... . ......... .................... . . . ...... . . . 186
`Use a List of Values When...
`. .. .... ..... ... .................... . 186
`Use a List of All Field Names in a Table When...
`. .. .. . ..... ..... ..... 186
`Setting Up a Lookup Field ........................ ....... . . ..... 187
`Defining Relationships among Tables .. · ..................... . ... .... 192
`Relating Two Tables ... ... . ...... ... ......... . .......... ..... . 194
`Saving the Relationships Layout ......... ... .. ... . ........ . . ... .. 198
`Redefining (or Deleting) a Relationship ...... ... .. ............ . .... 199
`Important Tips for AutoNumber Fields .............................. 199
`Changing the Starting Value of an AutoNumber Field ............ ..... 200
`Defining a Relationship When One Field Is an AutoNumber ............ 202
`Documenting Your Tables and Database ...... ............... . . . . . .. 203
`Analyzing Your Tables and Database Performance ..................... 204
`Where to Go from Here ..................... . . .................. 204
`
`207
`Chl Linking, Importing, and Exporting Data
`Link, Import, Export: What's the Difference? ................ , ......... 210
`Interacting with Other Databases ... .................... . ......... . 210
`Where You'll See Imported/Linked Tables .......................... 212
`
`
`
`....
`
`TABLE OF CONTENTS
`
`XIX
`
`Importing or Linking a Table ...... ... .............. . ..... .... . ... 213
`Importing or Linking Paradox Tables ............ .................. 215
`Importing or Linking dBASE and FoxPro Files ....................... 216
`Importing or Linking SQL Tables ......... ........................ 217
`Importing or Linking Other Access Databases ........... . ....... . . . . 218
`Using Linked Tables .. . . ... ................. ............ .... . ... 220
`Setting Properties of Linked Tables .. . ..... ....................... 221
`Renaming Linked or Imported Tables ........... . ...... ..... ...... 222
`Speeding Up Linked Tables . .. ............ . ..................... 222
`Using the Linked Table Manager ...... . ... .. .. .... . .............. 223
`Deleting the Link to a Linked Table ........ ....... ... . .. ........ .. 224
`Importing or Linking Spreadsheets and Text Files ..... . . . ...... . . .. . .. . 225
`Importing or Linking Spreadsheets ............................... 227
`Importing or Linking Text Files .. ................................ 230
`Using an Import or Link Specification ................... . ... . ..... 234
`Importing or Linking HTML Files ..... .............................. 237
`Refining an Imported Table's Design ......... .................... . .. 239
`Troubleshooting Import Problems ...... . .. .. ... . . . . ... . ........... 239
`Problems When Importing to New Tables .. ........................ 241
`Problems When Importing to Existing Tables ..... . .... . . ...... ..... 241
`Exporting Data from Access .............. .. ... ...... . ............ 242
`Exporting Objects ... .. ....................................... 243
`Exporting to Text and Excel 5-7 Files .... ......................... 244
`Exporting to Spreadsheets, Paradox, FoxPro, or dBASE ...... ........ . . 245
`Exporting to a SQL Database ................................... 245
`Exporting to Another Access Database ......... ................... 246
`Exporting to HTML or HTX Files ....... . .... .. .. .......... . ...... 246
`Using the Publish to the Web Wizard ............................ . 247
`Using Officelinks .............. ... . ............ . ... ... . . ..... 250
`Mailing an Access Object ........ ........ . ... . ......... .. ...... 251
`Importing and Exporting from Nonsupported Programs ...... .......... 252
`Where to Go from Here ...... . .................................. 253
`
`
`
`XX
`
`TABLE OF CONTENTS
`
`ChB Adding, Editing, and Viewing Data
`255
`Data sheet View and Form View .... ............................... 25 7
`Creating an Instant Form ................ .......... .. .......... 258
`Closing a Form ............... ............................... 259
`Viewing Data in Datasheet or Form View ............. .......... ... 259
`Switching between Datasheet View and Form View ..... ............. 260
`Customizing the Datasheet View ..................... ........... . . 261
`Using the Formatting Toolbar ................................... 261
`Changing the Datasheet Appearances in One Fell Swoop .. ..... ....... 264
`Selecting and Arranging the Datasheet Rows and Columns ............ 264
`Freezing and Unfreezing Columns ............. .................. 266
`Saving or Canceling Your Datasheet Changes . ............... . . . , . . . 267
`Navigating Forms and Datasheets ........... ...................... 267
`Adding Data to a Table ..................... ....... .............. 269
`Tips for Adding Records ............................... . ....... 270
`The Tiny Icons ......................... ..................... 271
`How Do I Insert a Record? ..................................... 271
`Changing Data in a Table ........... ............................. 271
`Navigation Mode versus Editing Mode ............................ 272
`Keys for Editing Table Data ........ .................... . ........ 272
`Selecting Records and Fields .......... ............................ 273
`Deleting Data ................................................. 275
`Deleting Data within a Field .... ................................ 275
`Deleting Records ............. ................................ 276
`Copying and Moving Data ....... ............................... . 276
`When Cut-and-Paste Won't Work ............................... . 277
`Using Hyperlinks in a Table ............... ....................... . 277
`Entering Hyperlink Addresses ........... ....... . ....... . ....... . 278
`Editing a Hyperlink Address ............. ....................... . 283
`Deleting a Hyperlink Address ........... ........ . .. . ........... . 283
`
`
`
`TABLE OF CONTENTS
`
`Using OLE to Store Pictures, Sounds, and Other Objects ................ 284
`About OLE Servers and Clients ........ .............. . . . . . . . ..... 285
`About the Source Program ........... ...... .. ....... .. .... ..... 285
`Linking versus Embedding .... .. .. . ... .. ... . .. . ................ 286
`An Easy Way to Insert Objects .... ........ . .... . . .... ... . ..... ... 286
`What the Object Looks Like ..... .... . . . ....... ..... ..... ....... 287
`Activating and Editing OLE Objects ... ............ . ....... ... . .... 288
`Other Ways to Insert Objects
`. ............ .. .... ................ 289
`About Bound and Unbound Objects ...... .. .. ... . ...... .. . ....... 292
`Special Techniques for Memo Fields .. .............................. 293
`Controlling the Enter Key Behavior ...... . .... .. . ... . ..... . ... ... . 293
`Special Techniques for Sizing Photographs ...... ............ .... ..... 294
`Step 1: Create the Table and Field ........... .............. ... .... 295
`Step 2: Create the Form . ........ . . ..... . ... . . .... .. ......... . . 295
`Step 3: Measure the Photo's Container . .. . . . . . . . ............. . .... 295
`Step 4: Scan, Crop, and Size the Photo ..... .. .. . ......... . ... .. .. . 296
`Step 5: Link or Embed the Picture .......... ............ .. ...... .. 296
`Troubleshooting Data Entry and Editing Problems . ..... . .... . ......... 297
`Duplicate Key Message . . ... . ... .... . .. ... .. ................... 297
`Can't Have Null Value in Index ...................... · . ....... . ... 298
`Value Isn't Appropriate for This Field Type .... ....... . ..... . ....... . 298
`New Records Seem to Disappear .......... .... ... ... ..... ....... 298
`Data Fails Validation Rule .. . .... . . . ... . ... ........... ..... . .... 299
`Access Won't Let You Add or Change Any Data ....... ... .. .. .. .... . 299
`Changing the Table Design from Datasheet View ......... ....... . ..... 300
`Renaming a Column ............... ....... . ... ... . .' . . . . ..... . . 300
`Inserting a Text Column ... ..... .