Function Backup File

Function Backup file

You will need to put this function under the Module then call it on the button On Click Event

Function BackupFile() As Boolean
 Dim Source As String
 Dim Target As String
 Dim retval As Integer
 Source = CurrentDb.Name
    ‘change your backup location here
 Target = "Z:\My Apps\Backups\YourFielName"
 Target = Target & Format(Date, "mm-dd") & " "
 Target = Target & Format(Time, "hh-mm") & ".accdb"
' create the backup
 retval = 0
 Dim objFSO As Object
 Set objFSO = CreateObject("Scripting.FileSystemObject")
 retval = objFSO.CopyFile(Source, Target, True)
 Set objFSO = Nothing
End Function

Some say that this condition can’t be treated but this is more common in online cialis mastercard younger men. On the other hand, levitra overnight shipping they cannot simply impose the goal. It is recommended that the fellows suffer from the heart disease should not take buy brand cialis as long and agonizing erections may show up. In physical aspect, the order sildenafil online most common culprit to impotence is vascular problems and neuropathy apart from cardiac/liver/insulin/kidney/pelvic disorders.

Related posts