Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB Databases
|
Pro VB Databases Advanced-level VB coding questions specific to using VB with databases. Beginning-level questions or issues not specific to database use will be redirected to other forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 23rd, 2004, 10:01 AM
Registered User
 
Join Date: Nov 2004
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default Restarting the current database

I have a database application for internal use at my company that often requires frequent updates. All users login via an .mde file which must be replaced after any updates.

Typically I have a setup program which the user reruns to update their code but what I'd like to do is run an automatic update that would copy over their local .mde file and then restart the application.

How can I tell Access to restart the current database? Or is there a better method? I figure there may be a .bat command or API call but don't know enough of either. Can anyone help?
 
Old December 27th, 2004, 07:55 PM
Registered User
 
Join Date: Dec 2004
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I'm not sure what your asking, but here is some info about MDE files.

If your database contains Microsoft Visual Basic code, saving your Microsoft Access database as an MDE compiles all modules, removes all editable source code, and compacts the destination database. Your Visual Basic code will continue to run, but it cannot be viewed or edited, and the size of your Access database will be reduced due to the removal of the code. Additionally, memory usage is optimized, which will improve performance.

Saving your Access database as an MDE file prevents the following actions:

Viewing, modifying, or creating forms, reports, or modules in Design view.


Adding, deleting, or changing references to object libraries or databases.


Changing code using the properties or methods of the Microsoft Access or VBA Object models — an MDE file contains no source code.


Importing or exporting forms, reports, or modules. However, tables, queries, data access pages, and macros can be imported from or exported to non-MDE databases. Any tables, queries, data access pages, or macros in an MDE file can be imported into another Access database, but no forms, reports, or modules can be imported into another Access database.
Caution Be sure to save a copy of your original Access database. If you need to modify the design of forms, reports, or modules in an Access database saved as an MDE file, you must open the original Access database, modify it, and then save it as an MDE file again. Saving an Access database containing tables as an MDE file creates complications reconciling different versions of the data if you need to modify the design of the forms, reports, or modules later. For this reason, saving a Access database as an MDE file is most appropriate for the front-end database of a front-end/back-end application.

Caution You won't be able to open, convert, or run code in a Microsoft Access 2000 MDE file in future versions of Microsoft Access. The only way to convert a Microsoft Access 2000 MDE file to a future version will be to open the original Access database the MDE file was created from, convert it, and then save the converted Access database as an MDE file.

Important Some restrictions may prevent you from saving your Access database as an MDE file:

If your Access database is secured with user-level security, you must meet certain criteria. Learn about using other forms of security with an Access database that is saved as an MDE file.


You must have password access to the Visual Basic code. Learn about protecting Visual Basic code.


If your database is replicated, you must first remove replication system tables and properties.


If your Access database references another Access database, or add-in, you must save all Access databases or add-ins in the chain of references as MDE files.
From MS Access Help - Working With MDE Files






Similar Threads
Thread Thread Starter Forum Replies Last Post
Restarting IIS zaghmout ASP.NET 2.0 Professional 1 November 7th, 2007 11:01 AM
Restarting a context in Tomcat 5? probedb Apache Tomcat 0 October 10th, 2007 03:00 AM
current cell darkhalf Excel VBA 2 June 26th, 2006 01:56 PM
restarting MySQL service resets all my privileges crmpicco MySQL 0 January 27th, 2006 11:33 AM
Making Copy of Current Access Database peterf VB Databases Basics 5 November 23rd, 2004 07:16 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.