0

I'm trying to recognize when a Notepad session closes so that I can run a program every time this occurs. I am using a Windows Embedded Standard 7 environment developing with TwinCAT3 which is cast inside of Microsoft Visual Studio. Does anyone know of a way to catch when a session closes?

1 Answers1

0

I think it is not possible to get all running processess in TwinCAT 3 system. If it was, it would be possible to check if a process (notepad) is running and then suddenly it isn't.

I would create a .NET program, for example with C#, to check system process list for notepad.exe. When the process disappears, the .NET program would write for example a BOOL value to PLC by using ADS commands. Then the PLC notices it and does whatever is needed. This program would be running in the background all the time.

See these links for example:

Quirzo
  • 1,183
  • 8
  • 10