Convert Text Into WAV Files
There are several situations where it would be to your benefit to listen to a WAV file rather than read a text file.
- When you are driving home.
- Someone who is visually impaired.
- You do not want the contents of a text file edited.
So, I started looking into how difficult it would be to create such a program. As it turns out, not very difficult.
I used AutoIT to create a simple executable that lets you either double click on the program and select a text file or drop a text file right on it. It will then automatically create a WAV file with the same name in the same folder as your original file.
You can download the MakeWAV application for free.
Also, if you are interested, here is the source code that you can copy and compile to make your own application. It’s open source so have fun!
#NoTrayIcon
Opt("MustDeclareVars", 1)
Dim $strTXTFile ;Name of the text file to convert to a WAV
Dim $strWAVFile ;Name of the WAV file to create
Dim $strTextData ;Text information to convert to a
WAV file
If $CmdLine[0] > 0 Then
$strTXTFile = $CmdLine[1]
Else
$strTXTFile = FileOpenDialog("Select Text File...", @MyDocumentsDir, "All (*.*)|Text files (*.txt;*.csv;*.log;*.msg;*.asc)", 1)
EndIf
If Not FileExists($strTXTFile) Then Exit
$strWAVFile = StringLeft($strTXTFile, StringLen($strTXTFile) - 3) & "wav"
$strTextData = FileRead($strTXTFile)
SplashTextOn("", "Creating WAV file. Please be patient.", 275, 20, -1, -1, 1)
_MakeWAV($strTextData, $strWAVFile)
Func _MakeWAV($strSentence, $strFileName)
Dim $oVoice ;SAPI voice object
Dim $oFilestream ;SAPI file stream object
$oVoice = ObjCreate("SAPI.SpVoice")
$oFilestream = ObjCreate("SAPI.SpFileStream")
$oFilestream.Open($strFileName, 3, False)
$oVoice.AudioOutputStream = $oFilestream
$oVoice.Speak($strSentence)
$oFilestream.Close
$oFilestream = 0
$oVoice = 0
EndFunc ;==>_MakeWAV
Well, it took over a year, but we now have definitive proof that the
I am in the process of performing some analysis on the posts on Daily Cup of Tech. One of the things that I want to do is a word count and frequency analysis on the entire blog.Now, I could go with good ol’ pen and paper and start counting every single word on the blog. But, that would take me quite a mount of time, not to mention that I would not learn anything in the process.

I was doing some research the other day on getting your self out of a difficult situation when you don’t have access to some vital system resources because you are running as a normal user and you lost your local admin password.
A new version (3.2.4.9) of AutoIt was released last Friday. If you are an avid AutoIt fan, make sure to update your version of AutoIt. You can 