Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.
cp \\target_machine local_file.txt c:\dest_file.txt
Assuming you have appropriate permissions, you can do it like this:
copy local_file.txt \\target_machine\c$\dest_file.txt
Use "c$" to reference C drive on the remote machine.
It's like this:
copy c:\local_path\local_file.txt \\target_machine\destination_path\destination_file.txt
If you have \\target_machine\destination_path\ mapped to a network drive, say, Z:
then the command becomes
copy c:\local_path\local_file.txt Z:\destination_file.txt
The network name cannot be found
system cannot find path specified error
Required, but never shown