1

I am writing a script in VBS for when I log in I am greeted with the time. However, the XML variable for voice pitch is not functioning without text that is static. Am I missing something?

Sapi.speak "<PITCH MIDDLE = '5'/>Good Morning"

This runs at a higher pitch...

Sapi.speak minute(time)

While this is normal.

I have tried "<PITCH MIDDLE = '5'/> minute(time)", <PITCH MIDDLE = '5'/>middle(time), and "<PITCH MIDDLE = '5'/>"middle(time). All of which return with errors.

I appreciate any help that is given. :)

1 Answer 1

1
+50

What you pass to the Speak method is a string. You are trying to pass a string and a number, so, all you should need to do is to concatenate both using the & concatenate operator to obtain a string with the full content

Sapi.speak "<PITCH MIDDLE = '5'/>" & Minute(Time)
Sign up to request clarification or add additional context in comments.

1 Comment

I appreciate this answer! Been 1 month since I asked and it finally works! Thank you so much!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.