Skip to content

Instantly share code, notes, and snippets.

@dck-jp
Last active August 29, 2015 13:56
Show Gist options
  • Save dck-jp/9105084 to your computer and use it in GitHub Desktop.
Save dck-jp/9105084 to your computer and use it in GitHub Desktop.
Create a mail byThunderbird Sample code
Sub CreateMailByThunderbird(address As String, _
subject As String, body As String)
Dim sPath, encodedSubject
With CreateObject("ScriptControl")
.Language = "JScript"
encodedSubject = .CodeObject.encodeURI(subject)
End With
sPath = "D:\Hogehoge\Thunderbird.exe -osint -compose "
arg = "mailto:" & address & "?" & _
"subject=" & encodedSubject & "&" & _
"body=" & body
Shell sPath & arg
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment