I have developed an database application with Delphi XE2 using an Access DB, now the problem is that I never added any backup and restore function into the application. The database will take a long time to get big, as it will only record about 30 records per day. So what I want to know is how to I write a function in Delphi that for example duplicates the database to a specific location, selected by the user. And also how to restore a backup from a location selected by the user.
Share
To backup and resstore an access db you must copy the
.accdb(or.mdbfor older versions) file to the location which you want. Just be ensure of close the existing connections to the db. To copy the file you can use theTFile.Copymethod.