473,395 Members | 1,869 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Copying my file to another location on the hard disk

Somebody help me.
How do i copy my Access database from one location on my hard disk to
another .
i tried file.copy(source, distination ) but the file would not move.
i always get this error message "Another process is using the
destinationFileName" .
thanks

Aug 24 '06 #1
2 1764
On 24 Aug 2006 04:14:24 -0700, "jatphat" <ja*****@gmail.comwrote:
>Somebody help me.
How do i copy my Access database from one location on my hard disk to
another .
i tried file.copy(source, distination ) but the file would not move.
i always get this error message "Another process is using the
destinationFileName" .
thanks
"File.Copy" by design does not allow a file that is currently open to be copied.
It appears that you are trying to create a copy of an Access database file that is currently open
and in use.

If using VB2005, you might look at My.Computer.FileSystem.CopyFile method which, I believe, will not
error on copying open files.

Gene
Aug 25 '06 #2
I am using vb.net 2003 and i am not able to use the file.copy
(source,destination) to copy my access file that is not opened to
another location on my hard disk
gene kelley wrote:
On 24 Aug 2006 04:14:24 -0700, "jatphat" <ja*****@gmail.comwrote:
Somebody help me.
How do i copy my Access database from one location on my hard disk to
another .
i tried file.copy(source, distination ) but the file would not move.
i always get this error message "Another process is using the
destinationFileName" .
thanks

"File.Copy" by design does not allow a file that is currently open to be copied.
It appears that you are trying to create a copy of an Access database file that is currently open
and in use.

If using VB2005, you might look at My.Computer.FileSystem.CopyFile method which, I believe, will not
error on copying open files.

Gene
Aug 25 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

22
by: Bryan Rickard | last post by:
I wrote a simple program in VB6 to copy all the files from a directory on a CD-ROM to my hard disk. There are about 10 files, each about 30MB. The program uses Get and Put to get data from the...
11
by: MLH | last post by:
I don't know how it happened. I have hundreds of hours worth of work invested in a file I foolishly named DB9.mdb. I was intending on renaming the file soon. But I neglected to do so before...
6
by: Jim Heavey | last post by:
I have written a little application which copies files from one location to another location. Before it copies the file, it ensure the directory for both the from and to locations is valid. It...
16
by: Otie | last post by:
Hi, Is there a way for VB5 to determine exactly where on a hard drive a .exe file is stored upon the .exe file's first copying to the hard drive? What I need to know is the exact hard drive...
3
by: noridotjabi | last post by:
Say I'm writting a program. In this program for some reason I need to store data somewere were I will be able to access it again. I don't want to store it in a file because then it could be...
13
by: =?Utf-8?B?Um9iS2lubmV5MQ==?= | last post by:
Hello, Here is a head scratcher for you all: We were wondering if it is possible to redirect file input to a place in memory (say a byte array for example). More specifically, if a function...
1
AdrianH
by: AdrianH | last post by:
Assumptions I am assuming that you know or are capable of looking up the functions I am to describe here and have some remedial understanding of C programming. FYI Although I have called this...
12
by: glennanthonyb | last post by:
Hi The company I work for has finally woken up to data security on our field laptops. I'm writing something in C# that will allow remote deletion of sensitive data and I don't believe...
2
by: chazzy69 | last post by:
This is a little hard to explain but i will try to make it as clear as possible. Firstly here's the setup, 2 databases on 2 different servers (databases are identical) now within the first...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.