To read the file from the FTP, we can use below script:
$webclient = New-Object System.Net.WebClient
$webclient.Credentials = New-Object System.Net.NetworkCredential('ftp username','ftp password')
$uri = New-Object System.Uri('ftp path')
$webClient.DownloadFile($uri, 'local path')
No comments:
Post a Comment