Hello,
A few days ago my friend need a Visual Basic Script to verify if a process is running and if it is send an e-mail. He asked me for help to code it, and I helped him.
Visual Basic Script to verify if a process is running and notify via e-mail.
Verify if a process is running with Visual Basic Script and shows a window if it is.
[code lang=”vb”]
set service = GetObject (“winmgmts:”)
for each Process in Service.InstancesOf (“Win32_Process”)
If Process.Name = processName then
wscript.echo “Notepad running”
wscript.quit
End If
next
[/code]
Send an e-mail using Visual Basic Script
[code lang=”vb”]
Const username = “USERNAME”
Const password = “PASSWORD”
Const smtpServer = “smtp.gmail.com”
Const port = 465
Const secure = True
Const userFrom = “FROM”
Const userTo = “TO”
Const emailSubject = “Subject”
Const emailText = “Text”
‘== CODE ==
Const cdoSendUsingPickup = 1 ‘Send message using the local SMTP service pickup directory.
Const cdoSendUsingPort = 2 ‘Send the message using the network (SMTP over the network).
Const cdoAnonymous = 0 ‘Do not authenticate
Const cdoBasic = 1 ‘basic (clear-text) authentication
Const cdoNTLM = 2 ‘NTLM
Set objMessage = CreateObject(“CDO.Message”)
objMessage.Subject = emailSubject
objMessage.From = userFrom
objMessage.To = userTo
objMessage.TextBody = emailText
‘==This section provides the configuration information for the remote SMTP server.
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/sendusing”) = 2
‘Name or IP of Remote SMTP Servesr
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/smtpserver”) = smtpServer
‘Type of authentication, NONE, Basic (Base64 encoded), NTLM
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/smtpauthenticate”) = cdoBasic
‘Your UserID on the SMTP server
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/sendusername”) = username
‘Your password on the SMTP server
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/sendpassword”) = password
‘Server port (typically 25)
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/smtpserverport”) = port
‘Use SSL for the connection (False or True)
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/smtpusessl”) = secure
‘Connection Timeout in seconds (the maximum time CDO will try to establish a connection to the SMTP server)
objMessage.Configuration.Fields.Item _
(“http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout”) = 60
objMessage.Configuration.Fields.Update
objMessage.Send
[/code]
This two scripts are changed to work together to do what we want and have a config section.
Best Regards,
Matheus
References:
http://wiki.imacros.net/send-email.vbs
http://www.techimo.com/forum/applications-operating-systems/117464-need-vbulletin-script-check-see-if-process-running.html
fast withdrawal casino usa 2021, how to memorize united statesn roulette
wheel and online pokies paysafe united states, or best online casino sites for real No Money Down Casino canada
online mobile Automaten casino auszahlung in sekunden
australian online casino apps, new zealandn roulette table and new
zealandn free slots no download, or awesome online casino new zealand
Check out my web page – Different ways To play mexican Bingo
uptown pokies australia review, no deposit required online casino usa and casino listings usa,
or usa $200 no deposit bonus 200 free spins
Check out my blog :: latvia gambling [Jeannette]
usa casinos that accept paypal, 888 casino
canada promo code and casino online real money canada, or australia online gambling stock
Feel free to visit my webpage: roulette software forum
online casino ohne deutsche lizenz bitcoin skrill ab 50 euro
virtual poker with friends uk, casino online free zinger spins
(Jaqueline) no deposit uk and free slots
that pay real money usa, or casinos that accept neteller australia
Online Casino Ab 2 Euro Neteller
blackjack mit revolut
eur 5 deposit casino uk, free pokie games nz and new gambling
legislation united states, or safe online potawatomi
casino app (Erica) australia
no deposit australian pokies, united kingdom gambling revenue and
best online casino app usa, or casoola sac n fox casino shawnee ok uk login
usa casino no deposit bonus code, free spins pokies in canada
and free bonus no deposit casino usa, or united statesn casino regulation
Feel free to visit my page :: Home Gambling Card Games
best poker room in united states, free spins no deposit casinos canada and united statesn real
money casino, or best nz casino bonuses
Look into my blog post … argumentative essay on gambling (Shawn)
ganar 10 euros al día apuestas
de la europa league
no deposit online pokies nz, no deposit sign up bonus nz 2021 and united kingdom slots machines, or canadian online
casinos pokies
Here is my blog post can you be good at gambling (Nigel)
online gambling laws in uk, valley forge casino Winners 2021 no deposit uk and united statesn casino slots online, or blackjack lusaa meaning
new zealandn online casino 5 dollar min deposit, usa who owns scarlet pearl casino opening dates and free spins
no deposit casino uk new, or cma uk gambling
parx casino sign up free play, Emerson,
brisbane united states, 888 casino nz and instant payout casino uk, or online bingo
for prizes in uk
sitios de apuestas deportivas; Lanora, deportivas foro futbol
online Live Casino Echtgeld Bitcoin
im ausland spielen
casino apps 5 walzen Slots mit Bonus paypal
live casino progressive jackpots casino; https://Ashwin-ushas.com,
cashtocode
casino ohne lugas echtgeld
Here is my web site :: 0 gerade ungerade roulette [https://Kook-Freiburg.De/]
dürfen beamte glücksspiel
my website: online live casino ohne limit (Seymour)
ruby fortune online pokies canada, no deposit online casino united
states and canadian casino sign up no deposit bonus,
or casoola casino uk login
my page: coupons biloxi casinos – Odell –
gambling taxes australia, united kingdom online casino free bonus
no deposit required and online craps bet number (Yvette) australia, or niagara falls usa casino