run an .exe file onload in VB.NET codebehind

D-Dawgg picture D-Dawgg · May 9, 2013 · Viewed 7.4k times · Source

i have song data (title and artist) that display on a web page. I would like to display this info on a twitter account and have found this great twitter .exe file that will tweet what ever i want to the twitter account. How do i simply run an .exe file from the code behind page to execute this twt.exe file?

Answer

Darin Dimitrov picture Darin Dimitrov · May 9, 2013

You could use the Process.Start method:

Process.Start("c:\somepath\twt.exe")

and if you wanted to pass arguments:

Process.Start("c:\somepath\twt.exe", "arg1 arg2 arg3 ...")

Or even better, take a look at the Twitter OAuth developer page and directly use their public API.