Nice script, I added some I/O to make it less hard coded. Check it out:
'******************************************************************************************
'* Scriptname: PostToTwitterSimple.vbs
'* TWITTER STATUS UPDATE
'* Brad Shultz - crribs.com
'* I/0 added by Adam Nottingham
'******************************************************************************************
strUsername = UserInput("UserName: ") 'prompts for username
Wscript.Echo " "
strPassword = UserInput("Password: ") 'prompts for password
Wscript.Echo " "
strMessage = UserInput("Enter Message: ") 'Message for twitter
strTwitterXMLResponse = SendToTwitter(strMessage, strUsername, strPassword)
MsgBox strTwitterXMLResponse, VbOkOnly, "TWITTER STATUS UPDATE" 'postback what you sent to twitter
Function UserInput( myPrompt )
' Check if the script runs in CSCRIPT.EXE
If UCase( Right( WScript.FullName, 12 ) ) = "\CSCRIPT.EXE" Then
' If so, use StdIn and StdOut
WScript.StdOut.Write myPrompt & " "
UserInput = WScript.StdIn.ReadLine
Else
' If not, use InputBox( )
UserInput = InputBox( myPrompt )
End If
End Function
Function SendToTwitter(strMessage, strUsername, strPassword)
Set objHTTP = CreateObject("Microsoft.XMLHTTP")
objHTTP.open "POST", "http://twitter.com/statuses/update.xml", false, strUsername, strPassword
objHTTP.send "status=" & strMessage
'SendToTwitter = objHTTP.responseText
Set objHTTP = nothing
End Function