MultiUse/ SingleUse-Active-X-Exe question:
There is a great post that my question builds on:
I would like to find out how I can let the Active-X-Exe terminate. During development it happens quite often that I have to set back my application, and since my Active-X-Exe works with the comm ports, I must reboot quite often when the Active-X-Exe does not terminate in a normal way and closes the comm ports again.
There I have a form inside the ActiveX-Exe that has a timer.
Each 5 seconds the timer calls the FindWindow procedure to determine if the client is still alive. If FindWindow returns 0, it shall terminate itself.
But calling this code (in the module) does not really do anything:
Public Sub UnloadAll()
MsgBox "unload all"
Unload mForm
Set mForm = Nothing
gObjectCount = 0
Set gSystemVariable = Nothing
End Sub
My Active-X-Exe stays alive.
I played around with it some hours now, but I could find the solution.
Thank you.
There is a great post that my question builds on:
I would like to find out how I can let the Active-X-Exe terminate. During development it happens quite often that I have to set back my application, and since my Active-X-Exe works with the comm ports, I must reboot quite often when the Active-X-Exe does not terminate in a normal way and closes the comm ports again.
There I have a form inside the ActiveX-Exe that has a timer.
Each 5 seconds the timer calls the FindWindow procedure to determine if the client is still alive. If FindWindow returns 0, it shall terminate itself.
But calling this code (in the module) does not really do anything:
Public Sub UnloadAll()
MsgBox "unload all"
Unload mForm
Set mForm = Nothing
gObjectCount = 0
Set gSystemVariable = Nothing
End Sub
My Active-X-Exe stays alive.
I played around with it some hours now, but I could find the solution.
Thank you.