-1

I'm trying to write a program which waits for a specific app (matlab in my case) to launch and does stuff when the app launches.

I see that I had to write a windows service application and managed get this working. I can see the service in Service Manager and can start-stop it. But I don't know how can "listen" or understand if Matlab (or any other app.) is launched. I'm kinda newbie when it comes to Windows Programming. Can you help me in this?

I'm using c++ with visual studio 2013.

closed as unclear what you're asking by gnat, GlenH7, MetaFight, user40980, user22815 May 7 '15 at 15:28

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Unclear what help you need. Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it’s hard to tell what problem you are trying to solve or what aspect of your approach needs to be corrected or explained. See the How to Ask page for help clarifying this question. – gnat May 7 '15 at 13:13
1

I believe this answer on Stack Overflow may help.

https://stackoverflow.com/questions/1591342/c-how-to-determine-if-a-windows-process-is-running

You just need to know what the process name is for Matlab.

Also, just Google:

"windows check if process is running c++"

Not the answer you're looking for? Browse other questions tagged or ask your own question.