Page 1 of 1

Call a web page

Posted: Tue Sep 10, 2024 3:16 pm
by IBMOLIVIER
Hello everyone, I don't know where to post my question.
My question is the following: Can I call a web page via an AS400 program, for example when I use a function key like F5? If yes, how? Could you provide an example of code, please?

Re: Call a web page

Posted: Tue Sep 10, 2024 3:32 pm
by Scott Klement
What do you mean by "call a web page"?

Re: Call a web page

Posted: Tue Sep 10, 2024 3:43 pm
by IBMOLIVIER
What I mean is opening a web page via the AS400.
For example, I am on the AS400 in a screen, I press F5, and the web page https://www.scottklement.com/forums/pos ... eply&t=528 opens.

Re: Call a web page

Posted: Tue Sep 10, 2024 4:09 pm
by Scott Klement
So you want the 5250 emulator to open up a web browser? You aren't expecting the web page to work inside the 5250 emulator, are you?

What are you using to run the 5250 emulator? Is it Windows? Mac? Linux? Mobile?

What 5250 emulator do you use? Is it IBM Client Access? (This is long discontinued -- but so is the AS400 you keep mentioning). Or Access Client Solutions? Or something else, if so what?

Re: Call a web page

Posted: Wed Sep 11, 2024 7:03 am
by IBMOLIVIER
Hello Scott, no, I don't expect the web page to work in the emulator.
I want the emulator to open a web browser.
Yes, it's the IBM 5250 emulator from Client Access, it's on Windows.

Re: Call a web page

Posted: Wed Sep 11, 2024 12:51 pm
by IBMOLIVIER
With the following command lines, I was able to open a web browser, except that a DOS window opens first. Maybe you have something else to suggest to me. Here is my code:

STRPCO
MONMSG MSGID(CPF0000)
STRPCCMD PCCMD('start https://www.Google.ca/.')

Re: Call a web page

Posted: Wed Sep 11, 2024 6:40 pm
by Scott Klement
If you want something quick and dirty that works only on Windows and only with emulation software that supports STRPCCMD, try this:

Code: Select all

PGM                                                 
  STRPCO                                            
  MONMSG MSGID(CPF0000)                             
  STRPCCMD PCCMD('rundll32 url,FileProtocolHandler +
                  https://www.Google.ca/.')         
ENDPGM                                              

Re: Call a web page

Posted: Thu Sep 12, 2024 1:23 pm
by IBMOLIVIER
it's work
tks Scott