Jump to content

Check if process is opened for X times


Recommended Posts

Hello, i'll explain. I need to check if a software is lauched for a third time, in that case i need to close the process related to the software ( is for automating software purpose, a conflict )

Example:

1) Notepad is open and then close, OK no problem +1

2) Notepad is open and close, OK no problem +1

3) Notepad is open ( is the third time! ) then ProcessClose

There is no risk of multiple istance so in theory is "simply" but i can't resolve. Thanks

Link to comment
Share on other sites

MyEarth,

Not enough info:

     1) Notepad is open and then close, OK no problem +1

     2) Notepad is open and close, OK no problem +1

         Opened by a specific process or any instance of NotePad?

     3) Notepad is open ( is the third time! ) then ProcessClose

         Over what period of time or set of events?

kylomas

Edited by kylomas
clarification

Forum Rules         Procedure for posting code

"I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs treat us as equals."

- Sir Winston Churchill

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...