title: Creating a directory on remote FTP using powershell
body: <p>I"m able to put a file up to a remote FTP with a modified version of...</p>
  
  <pre><code>          $File = "D:\Dev\somefilename.zip"
            $ftp = "ftp://username:password@example.com/pub/incoming/somefilename.zip"
  
             "ftp url: $ftp"
  
            $webclient = New-Object System.Net.WebClient
            $uri = New-Object System.Uri($ftp)
  
            "Uploading $File..."
  
            $webclient.UploadFile($uri, $File)
  </code></pre>
  
  <p>I'm running into the problem that I"m trying to upload a file to a directory that doesn't exist, the put fails.  So I need to create the target directory first.  GET-MEMBER doesn't seem to show any methods I can invoke to create a directory, only file operations.</p>