Kill job after closing navigator

Use this board to ask questions or have discussions with other Rich Displays users.
Post Reply
infgge00
Profound User
Posts: 28
Joined: Mon May 05, 2014 4:15 am
First Name: Giovani
Last Name: Garcia Estevez
Company Name: SISA, S.L.
Contact:

Kill job after closing navigator

Post by infgge00 »

Hi! I would like to know, how to kill the current job when I launch profound session and I close navigator.

At the moment, the current process is waiting for a response and I would like to kill then after closing navigator.

Sorry for my English!!
dieter
Experienced User
Posts: 122
Joined: Tue May 22, 2012 6:45 am
First Name: Dieter
Last Name: Schröder
Company Name: Ecclesia Holding GmbH
State / Province: Outside Canada/USA
Country: Germany
Contact:

Re: Kill job after closing navigator

Post by dieter »

Hi,
what do you mean by "closing navigator"? Do you mean "closing the emulation"? I think if you close the profound session there should not be left an interactive session job.

Dieter
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Kill job after closing navigator

Post by Scott Klement »

You can end your Rich Display file application simply by ending your RPG program, as normal. (*INLR = *ON, Return.)

However, i'm not sure how to tell when the user launches navigator. Is it launched from within your PUI screen? Then you could potentially do it with some JavaScript... but, if it's just launched independently, I don't see how you can tell your program that it has been launched
infgge00
Profound User
Posts: 28
Joined: Mon May 05, 2014 4:15 am
First Name: Giovani
Last Name: Garcia Estevez
Company Name: SISA, S.L.
Contact:

Re: Kill job after closing navigator

Post by infgge00 »

I´ve explained too bad.

When I start a profound session and it produces and exception not handled, There is a message waiting for response in the job.
well, I would like to kill this instance when I close the navigator (Chrome in this case), because the final users are used to close navigator when an exception occurs, but the thread is waiting for response the error message.

I must take some English classes, I know haha. Thanks for your replies!!
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Kill job after closing navigator

Post by Scott Klement »

Oh, I see.. when an exception occurs, you want the job to end when you close the web browser.

Where I live, we don't call web browsers "navigator", so I didn't understand what you meant. I thought you meant IBM's tools (IBM i Navigator)

That aside, your English is easy to understand.
infgge00
Profound User
Posts: 28
Joined: Mon May 05, 2014 4:15 am
First Name: Giovani
Last Name: Garcia Estevez
Company Name: SISA, S.L.
Contact:

Re: Kill job after closing navigator

Post by infgge00 »

That´s it Scott!! I want to end job when I close the web browser even though an exception occurs.
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Kill job after closing navigator

Post by Scott Klement »

No, there's no way (that I know of) for Profound UI to automatically end these jobs.

So, I would suggest writing a program (can be an RPG, or maybe even a CL) that monitors for all exceptions, and when it receives an exception dumps the job log, etc. Maybe sends a message, or an e-mail, to whomever is in charge of maintaining your application.

That way, if an error occurs, it'll always be caught. There should be no need for Profound UI to handle it.

For example:

Code: Select all

    CALL PGM(THE-REAL-PGM)
   MONMSG MSGID(CPF0000) EXEC(DO)
     DSPJOBLOG OUTPUT(*PRINT)
     SNDMSG MSG('Error calling THEPGM') TOUSR(QSYSOPR)
  ENDDO
Have your PUI session call a program like that.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest