Skip to content

Verify if a process is executing and notificate via e-mail on Windows

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

Published inwindows

13,718 Comments

  1. best usa pc slot game, casinos online canada and top online pokies and casinos australian open, or registration bonus paradice
    casino il – Isidro – usa

  2. best casino bonuses 2021 usa, top online pokies and how many casinos around the world (Kala) canadian update and bet365 new zealandn roulette help, or free sign up
    bonus united statesn casino

  3. vox_zpKn vox_zpKn

    Zagladam tu regularnie od czterech miesiecy, wiec mam jakies zdanie. Trafilem tam przez znajomego z pracy, z lekkim dystansem. Kolekcja gier w Vox Casino robi wrazenie rozmiarem — Pragmatic, NetEnt, Play’n GO plus troche Betsoftu sa na miejscu, wiec Gates of Olympus czy Book of Dead odpalisz bez szukania.

    Glownie zostaje na zywym stole. Evolution obsluguje wiekszosc stolow, jakosc streamu jest w porzadku o kazdej porze. Lightning Roulette wciaga mnie najbardziej, ale to bardziej show niz rozsadna gra. Czego brakuje, to stolow po polsku, trzeba dogadac sie po angielsku.

    Bonus powitalny w Vox Casino to doplata do depozytu plus pakiet darmowych spinow rozbity na kilka dni, a spiny leca partiami przez piec dni, nie wszystkie naraz. Obrot ustawiony na x40 — ani rewelacja, ani skandal, po prostu rynkowa srednia. Wejsc mozna od 40 zl, rejestracja zajela mi doslownie dwie minuty. Aktualne kody promocyjne zawsze sprawdzam przez [url=https://aroneofficial.com/vox-casino-kody-2026-krok-po-kroku-rejestracja-i-aktywacja-bonusu]vox casino darmowe spiny[/url], bo czesc starych ofert juz wygasla. Uwaga: kod trzeba wklepac przed wplata, potem support juz nic nie zrobi.

    Wyplacanie schodzi u nich calkiem sprawnie. Na Skrillu mialem srodki po jakichs czterech godzinach, przelew na Visa/Mastercard potrafi sie ciagnac dwa-trzy dni robocze. Crypto tez jest, BTC i kilka innych, to chyba najszybszy kanal. Proces weryfikacji w Vox Casino zajal mi dwa dni — standardowy komplet dokumentow, to normalne przy licencji Curacao.

    Minus, o ktorym warto wiedziec — nie ma appki, tylko wersja przegladarkowa. Na telefonie wszystko sie skaluje poprawnie, jednak filtry gier na komorce sa tragiczne. Obsluga w Vox Casino odpowiada po polsku, odzew w kilka minut, choc raz o trzeciej w nocy trafilem chyba na bota. Ogolnie gram dalej, choc bez euforii.

  4. single_zlOr single_zlOr

    Been using Single Bet Calculator for the best part of a year, mainly at weekends when the football’s on, so make of that what you will. Their lobby’s bigger than I expected — somewhere around 3,000 games by my count, with the usual suspects in there: Pragmatic Play, Play’n GO, Betsoft. Sweet Bonanza and Book of Dead get most of my spins, although the Yggdrasil titles have been kinder to me.

    Their sign-up deal is 100% up to ?500 plus 100 spins, with wagering at 40x which isn’t the worst I’ve seen. Not gonna lie, it took me longer than I’d have liked — you’ve got 7 days on the spins, which felt tight. They do a little no deposit bit as well — about 20 spins for verifying your account, nothing life-changing but free is free.

    Live section is where I actually spend most of my time. Evolution power it, meaning you’ve got actual dealers, about 40-odd tables, and the game shows — Crazy Time, Monopoly Live, that lot. Never had a stream drop on me, which some sites still can’t manage. Worth a look at the up-to-date terms via [url=https://recentstatus.com/read-blog/7828]this site[/url] rather than trusting my numbers.

    Getting money out of Single Bet Calculator have been quick enough — Skrill came back in about a day for me, card withdrawals took 2-3 working days. You’ve got the usual cards, Skrill, Neteller, plus crypto, deposits start at a tenner. Verification was the annoying bit — standard documents which took 48 hours.

    Sign-up took me about five minutes, they hold a UK licence which is the main thing I check first. There’s no dedicated app, the mobile site just works in the browser and I’ve had no issues. The live chat at Single Bet Calculator runs round the clock, but you’ll wrestle with an automated agent before a human shows up. Once you get a person they’re fine.

  5. nonebet_rdkr nonebet_rdkr

    I’ve been playing at Nonebet for something like four months now, mostly on the train home, and figured I’d write something up since a mate asked me. Registration took me like two minutes — email, password, done, although the KYC bit came later, which every licensed site does anyway. Minimum was around $10 which is fine for a casual punter.

    There’s a stupid amount of games — I’d guess around 3,000 games last I looked. Play’n GO stuff is everywhere, so Gates of Olympus, Big Bass, the usual suspects get pushed hard. I tend to grind Big Time Gaming Megaways because the volatility suits me. NetEnt classics are in there too. Live dealer side runs on Evolution, which means actual dealers, roulette running 24/7 and Crazy Time and Monopoly Live if that’s your thing.

    The welcome deal when I joined was 100% to $500 with 150 spins, rollover sits at around 35x which is about average. They also had a small no deposit thing at one point but it comes and goes. Terms change fairly often so have a look at [url=https://biolinky.co/cjgf-n7iyns]Nonebet[/url] before you claim anything. What did get on my nerves was the max bet rule while wagering — I busted it by accident once and the balance got voided. Lesson learned.

    Withdrawals have been pretty quick. Crypto came back same day every time I’ve done it, Skrill and Neteller were about a day, but the Visa one took nearly four days which felt long. Funding is instant via card, Skrill, Neteller and the usual coins.

    Support answered me at 2am, not just a bot loop once you get past the bot. Nonebet doesn’t have a proper app as far as I can tell — it’s a browser thing, but it runs fine on my phone. It’s a Curacao licence, which isn’t the ACMA, obviously, make of that what you will if you’re in Australia.

  6. nonebet_uskr nonebet_uskr

    Been playing at Nonebet for about five months now, mainly late nights, and thought I’d dump some thoughts since someone asked me the other day. Getting an account took no time — email and a password, that’s it, although the ID verification hit me later, which is normal enough. Minimum was $10 which is fair.

    The lobby’s big — somewhere north of 3,000 slots and tables last I looked. Pragmatic Play stuff is everywhere, so Gates of Olympus and Sweet Bonanza are sitting right on the front page. My go-to is Yggdrasil and Betsoft titles when I want longer sessions. NetEnt back catalogue is there as well. Live dealer side is Evolution-powered, so you get real croupiers, blackjack tables at all hours plus Crazy Time and Monopoly Live if that’s your thing.

    Bonus-wise the offer when I joined was 100% up to $500 plus 100 free spins, wagering was 40x which honestly is nothing special. They also had a small no deposit thing at one point but it comes and goes. Terms change fairly often so have a look at [url=https://p5lcj.hp.peraichi.com/consulting_site_p2_2]peraichi DR91[/url] before you claim anything. The one thing that annoyed me is the $5 max bet cap during bonus play — I busted it by accident once and lost the lot. My fault, but still.

    Withdrawals have been decent. Crypto came back in under an hour both times, Skrill and Neteller were about a day, and the one card withdrawal dragged out to three business days which felt long. Funding is instant with Visa, Mastercard and the usual coins.

    Their live chat got back to me in about five minutes at midnight, not just a bot loop after the first canned reply. No app for Nonebet that I’ve found — it’s a browser thing, works well enough on the Android. Licensed out of Curacao, so not local regulation, something to be aware of if you’re in Australia.

  7. coin master link free coins and spins; Jasmine,
    chip no deposit casino bonus united states, united states
    poker tournaments and bingo the uk, or best online casino to win money united kingdom

Leave a Reply

Your email address will not be published. Required fields are marked *