Hi
I want to perform a Google speech in vbscript but i have some issues with this code :
So i get this Error
Line 10 Caract :5
The system cannot locate the resource specified
Code : 800C0005
msxml3.dll
I want to perform a Google speech in vbscript but i have some issues with this code :
Code:
input = InputBox("Enter a text to Speak","Enter a text to Speak")
HTTPDownload "[URL unfurl="true"]http://translate.google.com/translate_tts?ie=UTF-8&tl=fr&q="[/URL] &input,"c:\Gspeak.mp3"
Sub HTTPDownload(strFileURL,strHDLocation)
'MsgBox "[URL unfurl="true"]http://translate.google.com/translate_tts?ie=UTF-8&tl=fr&q="[/URL] &input
Set Ws = CreateObject("WScript.Shell")
Set objXMLHTTP = CreateObject("MSXML2.XMLHTTP")
objXMLHTTP.open "GET", strFileURL, false
objXMLHTTP.send()
If objXMLHTTP.Status = 200 Then
Set objADOStream = CreateObject("ADODB.Stream")
objADOStream.Open
objADOStream.Type = 1 'adTypeBinary
objADOStream.Write objXMLHTTP.ResponseBody
objADOStream.Position = 0 'Set the stream position to the start
Set objFSO = Createobject("Scripting.FileSystemObject")
If objFSO.Fileexists(strHDLocation) Then objFSO.DeleteFile strHDLocation
Set objFSO = Nothing
objADOStream.SaveToFile strHDLocation
objADOStream.Close
Set objADOStream = Nothing
End If
Set objXMLHTTP = Nothing
Ws.Run strHDLocation
Set WS = Nothing
End Sub
Line 10 Caract :5
The system cannot locate the resource specified
Code : 800C0005
msxml3.dll