Convert Text into Audio File without any external tool

Description
= A convenient trick to Convert Text into Audio File, this helps the user to listen generated audio clip while working on other stuffs. Generated file is portable in simple terms this file can run in any version of window machines. A user can use this file as like other files i.e. user can Email, copy-paste this file in other disks also.

Requirements

Windows machine with sound card!

Instructions/Installation/Usage

1- Open text editor. Let’s says Notepad.

2- Copy the below code and paste into Notepad file.
Dim text, sapi
text=“Onehack.us is the best site to learn many things!”
Set sapi=CreateObject(“sapi.spvoice”)
sapi.Rate = 2
sapi.volume = 100
sapi.Speak text

3- Save your file with any name with extension .vbs

4- And the audible file is created. Double Click the file and open to hear audio

Note

Values for the Rate property range from -10 to 10, which represent the slowest and the fastest speaking rates, respectively.

Values for the Volume property range from 0 to 100, representing the minimum and maximum volume levels, respectively.

If you face any issues or want to know more! Do let me know.

Thanks and regards
Ravi

7 Likes

Thanks for this awesome share.
I tested the code, and correct the code by changing the symbol ” by "
So it works. I’m using win 7.
:100:

4 Likes