Skip to content

Check-Month

Gets the current month name

try {
	[system.threading.thread]::currentthread.currentculture=[system.globalization.cultureinfo]"en-US"
	$MonthName = (Get-Date -UFormat %B)
	& "$PSScriptRoot/speak-english.ps1" "It's $MonthName."
	exit 0 # success
} catch {
	"?? ERROR: $($Error[0]) (script line $($_.InvocationInfo.ScriptLineNumber))"
	exit 1
}

This script has no configurable parameters.

An interactive directory of PowerShell scripts.