Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Team,
As I am trying to explore, I have a query again!!!
I want to read all files and folders present in a remote machine and manipulate them.
How can i achieve this using Windows C programs ( win32Api )
Atleast if can you please tell me any book or site which explicitly has information about these tasks which i wanted to perform.
Appreciate your responses.

Regards,
Kiran.
Posted

1 solution

Create a share on the remote machine that exposes the directory and give the proper access rights to both the share and the directory (including the files). Access the files with normal Win32API function for file access using UNC paths e.g.: \\server.domain.xxx\sharename\directory1\...\filename.extension
If you have administrative rights you can even use the admin shares \\server.domain.xxx\c$ etc.

This also means that the ports used in SMB would have to be open from your machine to the remote of course. This is more likely the case if you operating on a LAN opposed to a WAN connection where this most likely not the case.

Cheers!

-MRB
 
Share this answer
 
Comments
thatraja 30-May-11 12:28pm    
Fine, enough. 5!
Sergey Alexandrovich Kryukov 30-May-11 12:36pm    
Agree, a 5.
--SA

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



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