Quickie: Making a simple Text to Audio Application

Did you know we all have speaking engines in our windows PC? Well, there is a very neat trick by which you can use that speaker engine to speak a private message. This can be used if you want to record a computerized personal message or you are just trying to make a text to speak app and want to take advantage of the speaker engine. Below are the steps and the code you will require for it to work.

STEP 1: Open NOTEPAD.

STEP 2: Copy and Paste the following code to it.

Dim message, sapi
Set sapi = CreateObject("sapi.spvoice")
sapi.Speak "Welcome to ATOM"
message = InputBox("Text to Audio converter"+vbcrlf+"From - www.prefedge.com"+vbcrlf+"by-Prakhar Lohiya","ATOM" )
sapi.Speak message

STEP 3: Name it as whatever you want but it should be saved as “YourFileName.vbs” file and not .txt (Note this can be done by choosing all files option from the drop file menu). Just save it and it is ready to use.

You can save it anywhere but remember the place. You can save it on desktop as it will be easier to approach.

NOTE: It is necessary to store it in Visual Basic Studio (vbs) format.

STEP 4: Now go to the destination where you have saved it, and open it (by Double clicking or Right click a Open)

Now just write anything and this will convert it into audio.

Until next time!!!

This VBS file can be executed on all versions of Windows including Windows XPWindows VistaWindows 7Windows 8Windows 8.1 and Windows 10.

Prakhar Lohiya
Prakhar Lohiya

Writer

An adventurer, photographer, writer,who loves coding. Prakhar had been fascinated by machine learning and is currently enhancing his skills. He just Loves the new tech mostly the gadgets and science behind it.

  • Satnam Bhatia

    Thanks Dude.Really Helped a Lot..In Fun Situations 🙂

    Satnam Bhatia(You Know Who I am)