$webRequest = [System.Net.HttpWebRequest]::Create("http://go.microsoft.com/fwlink/?LinkID=149156")
$webRequest.Method = "GET";
$webRequest.UserAgent = "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"

$response = $webRequest.GetResponse()
$stream = $response.GetResponseStream()

$reader = New-Object System.IO.BinaryReader($stream)
$bytes = New-Object System.Byte[] $response.ContentLength 

for ($read = 0; $read -ne $bytes.Length; $read += $reader.Read($bytes,$read,$bytes.Length - $read) ){ }
[System.IO.File]::WriteAllBytes("c:tempSilverLight.exe",$bytes);

相关文章:

  • 2022-12-23
  • 2021-10-13
  • 2022-12-23
  • 2021-04-20
  • 2022-12-23
  • 2021-11-22
  • 2021-07-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-10-15
  • 2022-01-23
  • 2021-07-18
  • 2022-12-23
相关资源
相似解决方案