title: PowerShell FTP automation issue
body: <p>I am working on a FTP automation script that will upload certain files from a network share to a specific location on a FTP server. I found the below, but am unable to edit it to navigate to the desired destination directory.</p>
  
  <pre><code>#ftp server 
  $ftp = "ftp://SERVER/OtherUser/" 
  $user = "MyUser" 
  $pass = "MyPass"  
  
  $webclient = New-Object System.Net.WebClient 
  $webclient.Credentials = New-Object System.Net.NetworkCredential($user,$pass)  
  
  #list every sql server trace file 
  foreach($item in (dir $Dir "*.trc")){ 
      "Uploading $item..." 
      $uri = New-Object System.Uri($ftp+$item.Name) 
      $webclient.UploadFile($uri, $item.FullName) 
   } 
  </code></pre>
  
  <p>I have credentials to the FTP server but am defaulted to <code>/home/MyUser/</code> and I need to direct to <code>/home/OtherUser/</code>. I do have permissions to browse to and upload to that directory, but I can't figure out how to, essentially, cd to that location.</p>
  
  <p>Here is the current error received:</p>
  
  <pre><code>Exception calling "UploadFile" with "2" argument(s): "The remote server returned an erro
  r: (550) File unavailable (e.g., file not found, no access)."
  At line:26 char:26
  +     $webclient.UploadFile &lt;&lt;&lt;&lt; ($uri, $item.FullName) 
      + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
      + FullyQualifiedErrorId : DotNetMethodException
  </code></pre>