Home  |   French  |   About  |   Search  | mvps.org  

What's New
Table Of Contents
Credits
Netiquette
10 Commandments 
Bugs
Tables
Queries
Forms
Reports
Modules
APIs
Strings
Date/Time
General
Downloads
Resources
Search
Feedback
mvps.org

In Memoriam

Terms of Use


VB Petition

Modules: AccessCheck Utility

Author(s)
Paul Litwin

INFORMATION PROVIDED IN THIS DOCUMENT AND THE DNSStripper Utility IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED. THE USER ASSUMES THE ENTIRE RISK OF RUNNING THIS SOFTWARE.
Licensing: Anyone can use this program or modify the source code in anyway.
The author makes no warranties as to its use or misuse.

© Paul Litwin

This UI-less app checks to see if an local Access MDB file is older than a master Access MDB file and if so, copies the master version over the local version. It then starts up Access.

Download:

  AccessCheck Utility

Dependencies:

Requires the VB 6 runtime (MSVBVM60.DLL), ADO.NET 2.1 or later, and Access.

You need to start the app using 2-5 comma-delimited command-line parameters of the form:

AccessCheck localdb, masterdb, confirm, run_access, access_path

where

Param Name

description

localdb complete path to local mdb (required)
masterdb complete path to master mdb (required)
confirm True to display a confirmation dialog before updating local copy or
any other value to not display a confirm dialog (optional, default = False)
run_access other value to not display a confirm dialog (optional, default = False)
run_access = False to not run Access or
any other value to run Access after completion (optional, default = True)
(optional, default=C:\Program Files\Microsoft Office\Office\MSAccess.exe)
access_path path to access exe
(optional, default=C:\Program Files\Microsoft Office\Office\MSAccess.exe)

Example:

AccessCheck c:\Projects\CERC\DoveTrackingSQL.mdb, \\wd\_File_Server\tracking\Dove\DoveTrackingSQL.mdb, False, True, C:\Program Files\Microsoft Office\Office\MSAccess.exe

The version check is performed by looking at the value of the CurrentVersionDate date/time field in the tblVersion table. Only the first row of this table is checked. If the local date/time is less than the master date/time or, if no tblVersion table exists, or if the local version of the database is not found, the master version of the database is copied over the local version.

If the master database is not found or if the required parameters are not supplied, an error is generated and the program quits. Otherwise, after the check and copy are peformed the local Access database is launched.

Potential Issues:

Does not handle database passwords or Access security. However, if there is a need for this, let me know and I can incorporate that.

Hope it helps,
Paul


© 1998-2010, Dev Ashish & Arvin Meyer, All rights reserved. Optimized for Microsoft Internet Explorer