views:

303

answers:

3

Hi,

I have requirement to send all the files in the directory to a different machines, the directory may internally contain child directories.

Is there any help available on this?

One more doubt is: I also heard that we can send the files using FTP, if so which is the best between the two. Is there any help available for this?

I need to implement this on windows platform using vc++/c++

Thanks

+1  A: 

One possibility is the TransmitFile() function in the windows API. You'll have to traverse the directories to find individual files with your own code.

Steve Fallows
I guess, you are the only one, you has understood that i want to programmatically send the files using vc++ in windows.
coolcake
A: 

You should probably combine and compress the files/directories on the source end.
Transmit and unbundle on the other end.

A library to help (that is free) is bzip (http://www.bzip.org/)

You should be able to do everything in memory if you do it well but potentially you can also use intermediate files.

Martin York
A: 
  1. Sounds like a homework problem.
  2. FTP uses sockets internally.

Make an initial try at the problem and post it here. You'll get more help if people think you are trying, rather than just freeloading.

Michael J