Skip to content

Commit 8afe827

Browse files
authored
Merge pull request #12071 from MicrosoftDocs/main
5/14/2025 PM Publish
2 parents 59b6947 + 404766d commit 8afe827

File tree

4 files changed

+20
-20
lines changed

4 files changed

+20
-20
lines changed

reference/5.1/Microsoft.PowerShell.Core/About/about_Try_Catch_Finally.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to use the `try`, `catch`, and `finally` blocks to handle terminating errors.
33
Locale: en-US
4-
ms.date: 01/07/2025
4+
ms.date: 05/14/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_try_catch_finally?view=powershell-5.1&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Try_Catch_Finally
@@ -134,9 +134,9 @@ two `catch` blocks:
134134
```powershell
135135
try {
136136
$wc = New-Object System.Net.WebClient
137-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc","C:\temp\MyDoc.doc")
137+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc","C:\temp\MyDoc.doc")
138138
} catch [System.Net.WebException],[System.IO.IOException] {
139-
"Unable to download MyDoc.doc from http://www.contoso.com."
139+
"Unable to download MyDoc.doc from https://httpbin.org."
140140
} catch {
141141
"An error occurred that could not be resolved."
142142
}
@@ -248,9 +248,9 @@ the temporary file if it exists.
248248
try {
249249
$wc = New-Object System.Net.WebClient
250250
$tempFile = "C:\temp\MyDoc.doc"
251-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc",$tempFile)
251+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc",$tempFile)
252252
} catch [System.Net.WebException],[System.IO.IOException] {
253-
"Unable to download MyDoc.doc from http://www.contoso.com."
253+
"Unable to download MyDoc.doc from https://httpbin.org."
254254
} catch {
255255
"An error occurred that could not be resolved."
256256
} finally {

reference/7.4/Microsoft.PowerShell.Core/About/about_Try_Catch_Finally.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to use the `try`, `catch`, and `finally` blocks to handle terminating errors.
33
Locale: en-US
4-
ms.date: 01/07/2025
4+
ms.date: 05/14/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_try_catch_finally?view=powershell-7.4&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Try_Catch_Finally
@@ -134,9 +134,9 @@ two `catch` blocks:
134134
```powershell
135135
try {
136136
$wc = New-Object System.Net.WebClient
137-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc","C:\temp\MyDoc.doc")
137+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc","C:\temp\MyDoc.doc")
138138
} catch [System.Net.WebException],[System.IO.IOException] {
139-
"Unable to download MyDoc.doc from http://www.contoso.com."
139+
"Unable to download MyDoc.doc from https://httpbin.org."
140140
} catch {
141141
"An error occurred that could not be resolved."
142142
}
@@ -248,9 +248,9 @@ the temporary file if it exists.
248248
try {
249249
$wc = New-Object System.Net.WebClient
250250
$tempFile = "C:\temp\MyDoc.doc"
251-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc",$tempFile)
251+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc",$tempFile)
252252
} catch [System.Net.WebException],[System.IO.IOException] {
253-
"Unable to download MyDoc.doc from http://www.contoso.com."
253+
"Unable to download MyDoc.doc from https://httpbin.org."
254254
} catch {
255255
"An error occurred that could not be resolved."
256256
} finally {

reference/7.5/Microsoft.PowerShell.Core/About/about_Try_Catch_Finally.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to use the `try`, `catch`, and `finally` blocks to handle terminating errors.
33
Locale: en-US
4-
ms.date: 01/07/2025
4+
ms.date: 05/14/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_try_catch_finally?view=powershell-7.5&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Try_Catch_Finally
@@ -134,9 +134,9 @@ two `catch` blocks:
134134
```powershell
135135
try {
136136
$wc = New-Object System.Net.WebClient
137-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc","C:\temp\MyDoc.doc")
137+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc","C:\temp\MyDoc.doc")
138138
} catch [System.Net.WebException],[System.IO.IOException] {
139-
"Unable to download MyDoc.doc from http://www.contoso.com."
139+
"Unable to download MyDoc.doc from https://httpbin.org."
140140
} catch {
141141
"An error occurred that could not be resolved."
142142
}
@@ -248,9 +248,9 @@ the temporary file if it exists.
248248
try {
249249
$wc = New-Object System.Net.WebClient
250250
$tempFile = "C:\temp\MyDoc.doc"
251-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc",$tempFile)
251+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc",$tempFile)
252252
} catch [System.Net.WebException],[System.IO.IOException] {
253-
"Unable to download MyDoc.doc from http://www.contoso.com."
253+
"Unable to download MyDoc.doc from https://httpbin.org."
254254
} catch {
255255
"An error occurred that could not be resolved."
256256
} finally {

reference/7.6/Microsoft.PowerShell.Core/About/about_Try_Catch_Finally.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to use the `try`, `catch`, and `finally` blocks to handle terminating errors.
33
Locale: en-US
4-
ms.date: 01/07/2025
4+
ms.date: 05/14/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_try_catch_finally?view=powershell-7.6&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Try_Catch_Finally
@@ -134,9 +134,9 @@ two `catch` blocks:
134134
```powershell
135135
try {
136136
$wc = New-Object System.Net.WebClient
137-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc","C:\temp\MyDoc.doc")
137+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc","C:\temp\MyDoc.doc")
138138
} catch [System.Net.WebException],[System.IO.IOException] {
139-
"Unable to download MyDoc.doc from http://www.contoso.com."
139+
"Unable to download MyDoc.doc from https://httpbin.org."
140140
} catch {
141141
"An error occurred that could not be resolved."
142142
}
@@ -248,9 +248,9 @@ the temporary file if it exists.
248248
try {
249249
$wc = New-Object System.Net.WebClient
250250
$tempFile = "C:\temp\MyDoc.doc"
251-
$wc.DownloadFile("http://www.contoso.com/MyDoc.doc",$tempFile)
251+
$wc.DownloadFile("https://httpbin.org/MyDoc.doc",$tempFile)
252252
} catch [System.Net.WebException],[System.IO.IOException] {
253-
"Unable to download MyDoc.doc from http://www.contoso.com."
253+
"Unable to download MyDoc.doc from https://httpbin.org."
254254
} catch {
255255
"An error occurred that could not be resolved."
256256
} finally {

0 commit comments

Comments
 (0)