Hi
Does anyone know how I can use VBA to copy my backend database onto a CD-Writer?
I have the application in two sites and in both cases the paths are identical - a directory in the C:\ drive and the CD-Writer is in both cases the D:\ drive.
I tried using FileCopy giving first the source path and then the destination path, so it looked like this:
Dim strName1 As String ' Current name/location of DB
Dim strName2 As String ' New name/location of DB
strName1 = "C:\DataFiles\MicaPharm\MgmMethBe.mdb"
strName2 = "D:\MgmMethBe.mdb"
FileCopy strName1, strName2
But I got an Access error saying bad file name or number. I am guessing it doesn't like the D:\ drive even though it had a blank CD in the drive waiting.
I need to find a way of automating it since my users are suggesting that using Windows Explorer is a ad too complicated?!?
Any ideas?
Thanks in anticipation of any help
Malcy
Does anyone know how I can use VBA to copy my backend database onto a CD-Writer?
I have the application in two sites and in both cases the paths are identical - a directory in the C:\ drive and the CD-Writer is in both cases the D:\ drive.
I tried using FileCopy giving first the source path and then the destination path, so it looked like this:
Dim strName1 As String ' Current name/location of DB
Dim strName2 As String ' New name/location of DB
strName1 = "C:\DataFiles\MicaPharm\MgmMethBe.mdb"
strName2 = "D:\MgmMethBe.mdb"
FileCopy strName1, strName2
But I got an Access error saying bad file name or number. I am guessing it doesn't like the D:\ drive even though it had a blank CD in the drive waiting.
I need to find a way of automating it since my users are suggesting that using Windows Explorer is a ad too complicated?!?
Any ideas?
Thanks in anticipation of any help
Malcy