Title: When closing Menu launcher, should it's children programs stop as well Post by: Candy M. on January 29, 2018, 04:10:59 pm For our application we have a main program that displays a menu and the user
can launch any of the programs. Our question is, if the window for the main program is closed, should the other programs that were launched stop as well? I have included a sample. menu_launcher.4gl is main program. programa.4gl and programb.4gl are programs that can be launched. We see mixed results and are trying to determine a pattern. In some cases, the child programs stop as well, when the main program is closed. In other cases, the child programs will remain running. We are trying to determine what causes the child programs to continue running or stop. The child programs have a command "fglrun ......." When I run this on 3.10.11 GDC and close the program, the child process stops (Window is no longer seen). I'm using VPN into our office. When someone in our office runs it, closes the main program, the child process is still running (Window is still active). We are using same shortcut in our GDCs. I don't know if it something in OS or what. Our GDC connections are SSH in testing. I have also submitted case to USA support, just wondering if the community has insight on this. I'm sure it is something simple. Candy mtdefault.4st: Code mtstart.per: Code
Title: Re: When closing Menu launcher, should it's children programs stop as well Post by: Candy M. on February 05, 2018, 05:37:37 pm I wanted to followup with this post. We did determine it was something in my ssh tunnel that was closing the child programs.
What we wanted, was to not allow the menu launcher program to be closed if any of the children programs were still running, so we could have an orderly exit of our application. To accomplish this we used the base.Channel and ran a 'ps he --user user_name -o args' command in linux. Then we searched for the _FGL_PPID environment variable which appeared to be the linux process ID of the menu launcher. Then we could inform the user which programs were still running and ask them to please exit those programs. It appears to work and we got it working in GDC over ssh, GDC over http and with the GBC. Candy |