Applescript say command options not working

Hi all,

If i set up an execute applescript and use a line like:

say 'this is a test?'
it works - but I want to control the voice and speed. If I use the old options like:

say -v Victoria 'this is a test' -r 200
or
say '[[rate 200]] hello'

it no longer works - just silence
Q: Is there any newer better way to choose a voice and choose a speed rate?

UPDATE...

ok I found it - this seems to work well...

say "This is a test" using "Alex" speaking rate 180 pitch 42 modulation 60

https://developer.apple.com/library/archive/documentation/LanguagesUtilities/Conceptual/MacAutomationScriptingGuide/SpeakText.html

and while we are at it - here's the same in javascript (inside apple script editor)

var app = Application.currentApplication()
app.includeStandardAdditions = true

app.say("Just what do you think you're doing Dave?", {
using: "Alex",
speakingRate: 250,
pitch: 42,
modulation: 60
})

1 Like