473,387 Members | 1,575 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,387 software developers and data experts.

Copy file from source to destination

This may be pretty simple, but I need some help here.
Can anyone point me in the right direction to copy a file from one location to another in VB6 ? I have tried using File System Object but couldn't go much farther. "user-defined type not defined" error message pops up.

Thanks
Nov 4 '07 #1
3 3077
YarrOfDoom
1,247 Expert 1GB
You can try FileCopy(source,destination).

Yarr Of Doom
Nov 4 '07 #2
thanks for the prompt reply!!!
Nov 4 '07 #3
YarrOfDoom
1,247 Expert 1GB
It's nothing, I just happened to be at the right forum at the right time.

Note: You should include the filename as well in the path given as destination. Eg:
Expand|Select|Wrap|Line Numbers
  1. FileCopy("C:\folder\file.txt","C\anotherFolder\newNameForTheFile.txt")
Yarr Of Doom
Nov 4 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: needin4mation | last post by:
Hi, foreach (ListViewItem item in listViewFiles.Items) { MessageBox.Show(item.SubItems.Text + ", " + item.SubItems.Text); string source=item.SubItems.Text; string...
2
by: Pete Davis | last post by:
I'm getting an exception when trying to copy a file. I basically do a File.Copy(source, dest, false); source is the source full path and filename. dest is the destination full path and...
1
by: cattyangel | last post by:
I want to copy a file from a directory to another directory. I tried File.Copy(source\default.aspx, destination\default.aspx) however, after I run the code, a file with correct name(but 0K fil...
3
by: Shailesh Gajare | last post by:
Hi All, I have creating an ASP.Net application with two web servers. I am uploading a file which is being uploaded on one of the server, I want to copy the uploaded file on the other server at the...
1
by: Bala | last post by:
Hi all, First of all I just want to know this will work out or not. I am going to have a console application on my server. I am going to call that application from my asp.net page. i'll pass...
6
by: Darhl Thomason | last post by:
I thought I was creating a simple little app, but it's kicking my butt right now. I've searched the help and can't find enough to get me where I need to be. I'm creating a CD to distribute to...
4
by: jiang.haiyun | last post by:
Hello all, when i import SOAPpy, the python crashed and print out 'usage:copy source destination'. As follows: ############################ haiyun# python Python 2.4.1 (#2, Mar 28 2006,...
4
by: Jassim Rahma | last post by:
hello, i want to know how can i copy a file in a way if it was stopped for a reason it can continue from the last point just like what torrents and file download managers do? thanks..
2
by: xahlee | last post by:
In this week i wrote a emacs program and tutorial that does archiving a website for offline reading. (See http://xahlee.org/emacs/make_download_copy.html ) In the process, i ran into a problem...
2
by: foss | last post by:
hi all, I am not able to copy file from a directory in the server to another directory. Here, the source is outside the web root directory and the destination is inside the web root directory. ...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.