.
This commit is contained in:
@@ -8,7 +8,7 @@ try {
|
||||
|
||||
# Check for command-line arguments
|
||||
if (-not $args) {
|
||||
Write-Error "Error: No text provided. Usage: .\speak.ps1 'Your Text Here'"
|
||||
Write-Error "Error: No text provided. Usage: .\say.ps1 'Your Text Here'"
|
||||
exit 1
|
||||
}
|
||||
|
||||
@@ -20,8 +20,11 @@ $synth = New-Object System.Speech.Synthesis.SpeechSynthesizer
|
||||
|
||||
try {
|
||||
#$synth.SelectVoice("Microsoft David Desktop")
|
||||
$synth.SelectVoice("Microsoft Hazel Desktop")
|
||||
#$synth.SelectVoice("Microsoft Hazel Desktop")
|
||||
#$synth.SelectVoice("Microsoft Zira Desktop")
|
||||
$synth.SelectVoice("Microsoft Mark")
|
||||
#$synth.SelectVoice("Microsoft George")
|
||||
#$synth.SelectVoice("Microsoft Susan")
|
||||
# Speak the text
|
||||
$synth.Speak($text)
|
||||
#Write-Host "Text spoken successfully."
|
||||
|
||||
Reference in New Issue
Block a user