cancel
Showing results for 
Search instead for 
Did you mean: 

NWBC Service Maps

Former Member
0 Kudos

Hi,

I was wondering if anyone else has come across this issue I have with NWBC roles. Here is the scenaio, I am using one of the standard SAP roles SAP_SR_BUYER_5 as you can see this role has a top level folder called "Buyer" and it is marked to display as a Service Map:

When this role is displayed in the NWBC 4.0 PL11 (desktop) and I choose the Workcenter Overview I see this nice Service Map:

So far so good... but if I try to click on any of the links in the Service Map it appears to do nothing for a while and then I just get a blank page:

If I Right-Click on the canvas I can see that the page it is trying to call is /sap/bc/ui2/nwbc/?sap-language=EN&sap-theme=sap_corbu&sap-nwbc-node=app_window&sap-nwbc-object_id=4355

When I try to show the canvas in a standalone browser I get a JavaScript error:

But this may be misleading since it may be looking for the NWBC as the "opener".

Anyone have any suggestions? Seen the same thing?


Thanks,
Simon

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

That is a classic dynpro transaction. NWBC uses Webgui (SAP GUI for HTML) for those. Can you make sure your Webgui (ITS) works?

Former Member
0 Kudos

Hi Samuli,

I don't think that is 100% true. NWBC for desktop uses the Windows GUI if you want it to. In the scenario here the Service Map is just showing you what is available in your menu structure. Launching the same transaction from the NWBC menu opens the Windows GUI just fine... hence my confusion - why does launching from the Service Map work differently from launching from the menu?

Thanks,
Simon

former_member183060
Contributor
0 Kudos

Hello Simon,

A trace (fiddler2 and/or verbose) could be very useful...

BR

Melinda

Former Member
0 Kudos

Well I tested with the same role and the same way with Fiddler running, Webgui is used.

claudia_binder
Participant
0 Kudos

Hi Simon and Samuli,

Transactions linked in the service map show up in SAP GUI for Windows (embedded in a new tab), the same as transactions started from the Index page, New Tab page, Quick Launch, navigation panel etc.

I tested it with NWBC 4.0 PL11 and role SAP_SR_BUYER_5, selecting e.g. "Create Purchase Order" from the service map, and it works well (and I also don't have problems when using the UI2 NWBC runtime):

As Melinda said, a verbose trace would be helpful to see what's going wrong in your environments.

It should be like that (trace snippet):

=== AsyncNavigateLast:

canvasAppType=SapguiTransaction

suspendCurrentSession=False

url=https://<server>:<port>/sap/bc/gui/sap/its/webgui;~sysid=<sid>;~service=<4 digit service nr>?%7etransaction=ME21N&%7enosplash=1&sap-client=<nr>&sap-language=EN&sap-nwbc-context=[...]

connectionName=on <server>:<port> [CsRuntime: SAP NWBC Managed Runtime for ABAP]

nodeId=Q63~SAP_SR_BUYER_5:283

callingSessionId=cs-session:#2<null>

DisplayName=Create Purchase Order (ME21N)

window=[ShellWindow#cw1: Create Purchase Order (ME21N)]

(search for '=== AsyncNavigateLast';

=== AsyncNavigateLast:

canvasAppType=BrowserServiceMap

is set when the service map rendering is complete. The next  '=== AsyncNavigateLast' block designates the page that is called from the service map, in the above case transaction 'Create Sales Order (ME21N).)

It is important that the url contains a ~service parameter. If this one is missing, NWBC is not able to launch a SAP GUI for Windows, but only a Web GUI. And if even the Web GUI URL is missing or wrong...

So please, provide a trace for further analysis.

Best,

Claudia

Former Member
0 Kudos

Thanks. However, even in your trace SAP GUI for HTML is used:

url=https://<server>:<port>/sap/bc/gui/sap/its/webgui;~sysid=<sid>;~service=<4 digit service nr>?%7etransaction=ME21N&%7enosplash=1&sap-client=<nr>&sap-language=EN&sap-nwbc-context=[...]

Is SAP GUI for Windows still being launched for the transaction itself? I will trace it myself to understand it better.

claudia_binder
Participant
0 Kudos

This is the magic of NWBC for Desktop

With system id, service number (containing the instance number), transaction value etc. it is able to create and communicate with a SAP GUI for Windows connection.

former_member183060
Contributor
0 Kudos

Hello All,

Just one addition to Claudia's nice summary

NWBC uses this to CHECK if it is really a valid transaction, before it launches SAP Gui itself...

BR

Melinda

Former Member
0 Kudos

Thanks Claudia,

When I did the verbose trace I noticed that I never got as far as you describe. I can see the first '=== AsyncNavigateLast" for the service map, but none is generated for the call to the transaction. So I figured it wasn't getting that far.


I then ran a Fiddler trace and I could see a valid response coming back, in which I can see some JavaScript that builds a form and submits it automatically... this is a snippet:


<script type='text/javascript'>

      /* <![CDATA[ */

      pro54_version_hash = '\x22U\x7c6A551FAEA008EBFD0FB83080DD8365FF\x7c1\x7c8C14C9705C63C15568A34B4EE1565C16\x7c0\x23\x7c\x7c\x22';

      function pro54_do_load(){

        try{

          document.body.focus();

        }

        catch(e){}

        document.onreadystatechange = checkReadyState;

        var frm = document.getElementById("application_load");

        //get the opener window

        var openerString = "opener";

        var counter = 0;

        //20 limitation in case no opener is ever found...

        while(typeof opener=="undefined" && counter < 20)

        {

          openerString = "parent.window." + openerString;

          opener = eval(openerString);

          counter = counter + 1;

        }

        opener.pro54_fill_frm_details(frm);

        if(frm["sap-nwbc-obn"].value == 'Navigate.Absolute'){

          frm.action='/sap/bc/ui2/nwbc/?sap-nwbc-node=navigate_absolute&sap-nwbc-new_window=X';

        }

        frm["sap-nwbc-action_url"].value = '\x2fsap\x2fbc\x2fgui\x2fsap\x2fits\x2fwebgui\x3b\x7esysid\x3dMDE\x3b\x7eservice\x3d3200\x3fsap\x2dclient\x3d190\x26sap\x2dlanguage\x3dEN\x26sap\x2dnwbc\x2dcontext\x3d03HA333037D633D333D03332700D760C880F0E8A770A8D740D8A37353036B230363036D13330303270330001635F17570363434B0303431F00\x26\x257enosplash\x3d1\x26\x257etransaction\x3dME21N';

        frm.submit();

      }

      function checkReadyState()

      {

        if(document.readyState == "interactive")

        {

          setTimeout("close();" , 1000);

        }

      }

      window.onresize=pro54_resize;

      /* ]]> */

    </script>

You can see on line 15 it references the standard window.opener object (this was the JavaScript error I was referring to earlier).

I then went and looked up the window.opener in the context of IE 8... and there are quite a few posts about people having issues with IE 8 and opener, which seem to be related to the IE Security Zone settings.

So my guess right now is that I need to get the system NWBC connects to added to the IE "Trusted Sites" zone (at this customer it is locked down so I can't change it myself).

Once I do that I will update here and hopefully it will be the solution.

That brings me to another question I suppose... IE8 and NWBC... maybe I will start another thread for this... I know IE8 is supported for NWBC but I wonder how many problems there might be?

Many thanks for all your help,
Simon

Former Member
0 Kudos

Just an update... I am slowly making progress on this... I found that I get the same problem with Service Maps in NWBC for HTML. In this case I am using Chrome and when I look at the developer tools I can see some errors which I think might be the root cause of the issue.

It seems to be a document origin issue. The main NWBC frame relaxes the domain to company.com but the service map page (which is displayed in an iFrame) has the document domain of server.company.com so there is a security error that gets thrown. Basically a cross origin issue.

Does anyone know of a setting that controls the domain relaxation in NWBC?

Thanks,

Simon

Former Member
0 Kudos

Just to update this thread. Today I upgraded to NWBC 4.0 PL12 for the desktop and also upgraded the NWBC runtime to patch 35 in the ABAP system. Since then this issue has been resolved. I am not sure which one fixed it, but I am guessing it was the backend upgrade to patch 35.

I hope this might help someone else in future.

Thanks,

Simon

Answers (1)

Answers (1)

former_member183060
Contributor
0 Kudos

Hello Simon,

Please check if You use the latest Runtime, I haven't seen this error message in a long time.

Best regards

Melinda

Former Member
0 Kudos

Hi Melinda,

We are currently running runtime version 3.6.0.2 patch level 32:

I don't see anything noted in higher patches that would appear to fix the problem I am having. I suppose you will recommend any way to upgrade

Thanks,

Simon

former_member183060
Contributor
0 Kudos

Hello Simon,

Good approach Of course it is always good to have a most current Runtime

But I also suggest (as You use Desktop Client), to check the version also of the SAP Gui, and test

with the latest Patch.

Best regards

Melinda