locked Re: JTAlert name


Michael Black
 

But I want the distinction to last over a restart of my app too...and the PID won't do that.
The PID isn't a guaranteed association to any specific named instance 
Only thing I have to work with is Window names which I'm not particular fond of relying on that as it's app-specific.

Mike




On Saturday, November 21, 2020, 12:56:10 PM CST, HamApps Support (VK3AMA) <vk3ama.ham.apps@...> wrote:


On 21/11/2020 4:59 pm, Michael Black via groups.io wrote:
But if multiple JTAlert processes are started it can't tell the difference between them.

Would it be possible to add a /name=XXX option so each instance could have a unique name -- that way I can associate the task entry with a specific JTAlert window.

Unless you know of some other way to associate one JTAlert to a specific instance.

Mike W9MDB

Mike,


You can already do that. By design JTAlert ignores any unsupported command-line options.

However, that will not always be the case and should not be relied upon as a long term solution. Not all applications are so forgiving and will error when an unrecognized parameter is passed in the command-line. IMO, you should avoid relying on such a technique to identify specific instances of applications you need to manage.

IMO, a better technique is for your program to maintain an internal list of the OS assigned PID for each of the started applications and use that PID for managing the different instances. Likely your already capturing the PID when each application is started.

The "/name=xxx" technique will only work with the main JTAlert.exe executable. It is not passed to the processes started by JTAlert.exe like JTAlertV2.Manager.exe and JTAlertV2.Decodes.exe.

de Laurie VK3AMA



Join Support@HamApps.groups.io to automatically receive all group messages.