Chapter 26. STARTUP CHECKING SYSTEM ROUTINES USING DAO

IN THIS CHAPTER

All of Access's powerful features really don't mean much unless they're put to practical use. This also can be said of all the books concerning developing in the Access environment. One of the goals for this book is to give you practical examples while also giving advanced concepts.

This chapter gives you routines that you can add to your systems. These routines will save time and money in support and maintenance. When starting your application and creating useful routines, ask yourself the following questions:

  • What's a graceful way to keep track of the files needed for linking and unlinking tables?

Note

In Access versions before Access 95, the linking and unlinking of tables from other databases was referred to as attaching and unattaching, which can be somewhat confusing when you look at someone else's code.


  • How many times have you had to hunt down everybody on a network to ask them to log out?

  • How can a corrupted back-end database be repaired automatically from within your system?

  • How do you notify users that a new version of the application is available and force them to upgrade?

Note

The term back end refers to the shared files out on the network, whether in another native Access database file or in a SQL Server database. The front end is the local database that contains the application portion of the system (the forms, queries, reports, and so on). The methods described in this chapter are to be used with native Access back ends and might not work with SQL Server.


This chapter answers those questions and more. You'll see routines for the following actions:

  • Performing startup system checking

  • Setting up custom database properties

  • Notifying and logging users out of an application

  • Testing linked table connections

  • Testing and repairing corrupted databases

  • Checking and notifying users of a new version

While looking at how to do these techniques, you'll also see ways to do these things:

  • Read and write user-defined properties of a database

  • Create and delete files from Access

  • Look for files from Access, even hidden files

Note

As you can tell by this chapter's title, the routines have been created by using DAO. If you want to see the same routines that instead use ADO, check out the next chapter, “Startup Checking System Routines Using ADO.”


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.59.177.14