Skip to Content

Call URL from ABAP (Windows and Mac)

Seemingly simple task: have a pop-up screen (old timey dynpro variety) with a hyperlink that shall open a web page in (ideally) user's default browser. This is EHP6 7.31 system. SAP GUI 7.5.

After some Google search I found 3 ways to do that but none of them work as I'd like on Windows. Even worse, we have many users with Macs and none of those ways worked at all on a Mac. Below is what I've tried so far and the results.

1. Container using cl_gui_custom_container (like here): no reaction on Mac, on Windows 10 opens something that looks like an odd version of IE (not the default browser).

2. Use cl_gui_frontend_services like this:

CALL METHOD cl_gui_frontend_services=>execute  
EXPORTING  document  = ''

In Windows, this results in the message:

After allowing, opens URL correctly in the default browser. On a Mac, this returns path_not_found exception.

3. FM CALL_BROWSER - pretty much same result as 2, just a different verbiage in the message in Windows and PROG_NOT_FOUND error in Mac.

Problem: unfortunately, this doesn't work on Mac at all and even in Windows having those security messages is unacceptable because it'll scare and confuse the users.

Question: is there some other way to do this that would work as desired for both Windows and Mac (SAP GUI for Java on Macs)? Or am I doing something incorrectly with these options?

test1.jpg (22.1 kB)
Add comment
10|10000 characters needed characters exceeded

  • Hi Jelena,

    just wondering: have you tried with a fully qualified link like instead of just More and more browsers are getting "twitchy" about non https links which might contribute to any security warnings/hassles.

    And a general question: does SAP "honor" default browser settings or does it still have a built-in preference for Internet Explorer? If the latter is the case, could this play a role with your process not working on a Mac?



  • Thanks, Bӓrbel! Out of curiosity, I tried that but it didn't make any difference. I got the Mac error resolved by applying a note though (see my reply to Horst).

    Edit to add: I suspect the container (1st option in my question) could be hard-wired to IE. So yes, that would explain it not working on Macs. The other two options did honor default browser after the note correction.

  • Get RSS Feed

3 Answers

  • Best Answer
    Feb 26, 2018 at 04:31 PM

    Solved it with some help from Horst Keller, Federico Saab and Ishteyaque Ahmad (indirectly). Below is the whole solution.

    Went with cl_gui_frontend_services=>execute, as suggested (FM has the same result). The issue on Macs was resolved by installing the note 1177636. Got rid of the pop-up on PC by making a change in SAP GUI configuration as noted in this blog.

    This is the rule I've added (Google URL is used here just for testing):

    As a side note, I was curious why a security pop-up does not appear when we use the standard Application Help menu, for example. It also opens a URL in browser, essentially. Through some debugging found that it uses different parameters in the call:

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 22, 2018 at 07:11 AM

    You can switch off these security messages in the GUI options (adjust local layout). Unfortunately, every user has to do this on her PC.

    I myself use the same method cl_gui_frontend_services=>execute. Yes, there are problems with MAC, but normally they arise from the contents of the HTML files and not from the way they are called.

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 22, 2018 at 01:20 PM


    I am not familiar with Mac OS in this regard, but we normally use the cl_gui_frontend_services=>execute.

    As a workaround to your problem, I would try to have some external service that could be executed (via web service, operating system etc.) from SAP, having the URL as an input parameter to it.

    Add comment
    10|10000 characters needed characters exceeded