Click here to Skip to main content
15,891,782 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I would like to listen or check particular folder in system whether it contains any file or not in MFC socket programming (CSocket). So that, if file present, it should be sent to other application automatically.

What I have tried:

Tried usual CFile object and Open(). I'm wondering how to check the folder constantly or frequently?
Posted
Updated 15-Jan-19 17:24pm
v2

1 solution

 
Share this answer
 
Comments
rmds 16-Jan-19 0:58am    
That was really helpful! tqvm...
rmds 16-Jan-19 1:14am    
Now I'm able to spy and notify any changes in directory. How to send the modified files to other connected client application? Do I need to implement thread or any simple method available?
MadMyche 16-Jan-19 7:07am    
I suppose you could add on a "copy" command over the file system or a "push" to non-PCs
rmds 17-Jan-19 0:34am    
I'm not particularly using any button to transfer file. Once connection is made, the file should be transferred from server folder to client folder in same computer.
rmds 19-Jan-19 0:59am    
The purpose here to transfer files through MFC socket. Using copyfile() doesn't serve the purpose. Any input would be greatly appreciated. Thanks!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900