Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Error "Unable to connect to the remote server" when executed "Invoke-WebRequest" command

$
0
0

Hi there,

I am trying to capture .csv file from REST call. For that I have used Invoke-WebRequest cmdlet. The exact command is as follows:

>>Invoke-WebRequest $url -OutFile $cosmos11_Path -UseDefaultCredentials -TimeoutSec 65535

On executing this, I got this error - Unable to connect to the remote server

If I pasted URL in the browser then I get the CSV file. But command not working.

It was previously working fine. But I am facing this issue from last 4-5 days. Please help me out if anybody have any idea.

Thanks,

Prashant


PSA



Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>