title: How to map local drive to a remote server using C#
body: <p>I need to distribute a local msi installer to a number of remote servers.
  I assume, that the way to do it is to map my local drive (on which the msi is located) to those remote servers and then copy this file from the mapped local drive onto a specific directory of each server.</p>
  
  <p>At firs, I was trying to copy file to a remote server without doing any prior mapping:</p>
  
  <pre><code>System.IO.File.Copy(@"\\WIN-J02JG3AAV7P\temp\emcrpts_x64_v40.msi",
                      @"\\sharepoint2010\C$", true);
  </code></pre>
  
  <p>this did not work (error: the network path was not found)</p>
  
  <p>Then, I'm trying to map my local drive to a remote server, but I'm lacking the proper syntax.
  If I have a local C:\temp shared, what is the proper C# syntax to map it to a remote server named "sharepoint2010"?</p>