Backup and Restore for final user

mtagliaferri

Registered User.
Local time
Today, 12:53
Joined
Jul 16, 2006
Messages
550
Hi I have had a look on the forum but cannot find what I am looking for!!
I need to back up all the contents of the tables of a database in a certain folder and then restore it. The reason for all this is to be able to update the database with new features so that the final user can receive the update and restore the data.
How can I achieve this???
M
 
let Append it :

Dim db As Database, tbl As TableDef
Set db = CurrentDb()
Set tbl = db.CreateTableDef("Newtable")

tbl.SourceTableName = "table 's name"
db.TableDefs.Append tbl
db.TableDefs.Refresh
 
Hi, thanks for your reply, can you give me further information as I am quite new on VBA and ACCESS.
Thanks
Marco
 
Add Microsoft DAO Libabry to Reference

After click on button StoreBackup make An Onclick_Event
and type this code .
(This code below help you to copy one Table to another one)

'***** Create new table*****
Dim db As Database, tbl As TableDef
Set db = CurrentDb()
Set tbl = db.CreateTableDef("Newtable")

'***** access to Table 's Soucre*****
tbl.SourceTableName = "table 's name"
'***table's name is the name of which table you want to backup. ***

'***** And copy to Newtable*****
db.TableDefs.Append tbl
db.TableDefs.Refresh

*To backup you just do like this
Dim db As Database, tbl As TableDef
Set db = CurrentDb()
Set tbl = db.OpenRecordset("Table's name",
)

tbl.SourceTableName = "Newtable"
db.TableDefs.Append tbl
db.TableDefs.Refresh
 
mtagliaferri said:
Hi I have had a look on the forum but cannot find what I am looking for!!
I need to back up all the contents of the tables of a database in a certain folder and then restore it. The reason for all this is to be able to update the database with new features so that the final user can receive the update and restore the data.
How can I achieve this???
M
First off you need to split your database. That way the user will not loose their data when you post an updated version of the front end. Search around for there are plenty of threads discussing this.

This might interest you... Export All Database Objects Into Text Files
 

Users who are viewing this thread

Back
Top Bottom