cancel
Showing results for 
Search instead for 
Did you mean: 

Can't pass event from WebDynPro to JspDynPage - why?

Former Member
0 Kudos
46

I Created JSP project and embedded in main page script (in its title),

which subscribes to event by EPCM API,

EPCM.subscribeEvent("urn:ru.intertech.common.wd.component", "save",   go);

and created WebDynPro page that fires event using, when pressing on some bution:

WDPortalEventing.fire("urn:ru.intertech.common.wd.component", "save", navUrl);

but first code newer receives that event...

why so ?

____________

for test reason I tested firing EPCM event on same JSP page,

and it was received,

also

I tested receiving Portal event "urn:com.sapportals:navigation", "Navigate"

it was received on same JSP page.

both iViews is not URL isolated according their properties.

WebDynPro package is:

package ru.intertech.common.wd.component;

_____________

note from else people expirence:

Does it important that receiving and firing side must be in same package? as written there:

https://www.sdn.sap.com/irj/scn/thread?messageID=462647

"The problem was that I created the Sender Application in package "com.sender" and the Receiver Application in "com.receiver".

I created them in the same package and it works."

What means domain for JSP page or WspDynPro component?

Does it important?

=================

JSP code is (changed script formattin to be able to post here, and removed else business content):

[hbj_content  ]
  [hbj_page_title"]
  
  [script_type="text/javascript__"]
  //alert["title started"];
  //EPCM.subscribeEvent["urn:com.sapportals:navigation", "Navigate", eventHandlingFunctionName];  
  //EPCM.subscribeEvent["urn:ru.intertech.navigation:epcm", "Navigate", eventHandlingFunctionName];  
  //EPCM.subscribeEvent["urn:ru.intertech.navigation:epcm", "Navigate",   pop];    
  //EPCMP.subscribeEvent[ "urn:ru.intertech.navigation:epcm", "Navigate", window,"eventHandlingFunctionName"];

    EPCM.subscribeEvent["urn:ru.intertech.common.wd.component", "save",   go]; 
   
	EPCM.subscribeEvent["urn:com.sapportals:navigation", "Navigate", eventHandlingFunctionName];  
	EPCMPROXY.subscribeEvent["urn:ru.intertech.common.wd.component", "save"  , window,   go]; 

  function eventHandlingFunctionName[ eventObj ]
  { 
	alert["title started=" + eventObj.sourceId + ": " + eventObj.dataObject  ];
  }
  
  function go[ evt ]
  { 
	alert["go started=" ];
  }  
  
  </script>
   <hbj:form id="myFormId" >

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

The first thing that came to my mind was the question "are the pages in the same domain?" Since we are dealing with client-side scripting I thought maybe it is not working because the WD and Portal Component are served from different servers in different domains??? or maybe you are not using Fully Qualified Domain names for the servers. Of course if they are running on the same server then I guess that is not the problem.

Have you tried using a JavaScript debugger to debug the code. I can recommend firebug for firefox.

Maybe I am totally off base... but I hope it helps,

Simon

Former Member
0 Kudos

your reply is worth.

what is the domains for views on one page?

where to see it?

Also, standard SAP MDM controls which we are using not working under any other browser except IE,

I tested on FF and Google Chrome, they do not erform dynamic part of the controls.

Despite this, debugging of scripts is important thing, so every piece is worth.

_________________

One more detail:

Also, two such a controls do not receive events from each other,

but ony within self..

why so ?

Edited by: Vladimir Grigoryev on Jan 27, 2009 10:00 AM