cancel
Showing results for 
Search instead for 
Did you mean: 

Webdynpro and URL parameter passing

Steven_UM
Contributor
0 Kudos

Hi folks,

With the ITS concept, one could pass on a couple of parameters (like the good old 'okcode') when calling an ITS application in order to bypass the first screen ... We are using it to bypass a customer logon screen for those customers that are already logged on via the portal ....

How does this fit with webdynpro applications? Passing parameters is ofcourse standard HTTP behaviour but how is it handled by a webdynpro application? Are the parameters by default available in the context controller? Can one bypass a complete view (so like the okcode for ITS) ?

Thx,

Steven

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Steven,

All URL parameters with prefix "app." will be passed to the Startup-plug of your (component)Interface View. Within the IDE you need to define the appropriate startup-plug within the interface view with the desired parameters.

Best regards, Karin

Former Member
0 Kudos

Hi Karin,

I tried to create a parameter in the ComponentInterfaceView starting with app. - the wizard refuses to accept such parameter names.

Could you get a little more detailed on how to read the values of the passed parameters in the view where they would be needed.

Thank you

Michael

Former Member
0 Kudos

Hi Michael,

I found a description for you. Hope this mechanism is discribed good enough so that you can easily follow it:

The Navigation between two different Web Dynpro Applications can be

triggered by declaring an Exit Plug inside the Interface View Controller

of Application 'StartApp' with a parameter named 'Url' of type string.

The Url-parameter contains the qualified Url of the target Application

belonging to the target component (may be the same like the start comp).

For being able to fire this exit plug, a view controller

must first declare a controller usage for the Component Interface

View Controller: wdThis.wdGet.fireExitPlug

(url). The url to Application 'AnotherApp' can be retrieved by calling

WDURLGenerator.getApplicationURL("local/WebDynpro_InterAppsNavigation",

"AnotherApp") for a local DC, otherwise "com.sap/WebDynpro_InterAppsNav"

A URL-Parameter can easily be added to this URL by simple string

concatenation: urlToAnotherApp="?app.parameter="paramterValue;

So the caller transfers the paramter via URL. The target (here the

Startup-Plug-Eventhandler inside InterfaceViewController of 'AnotherApp'

('AnotherApp' must declare which startup-plug of which

Interface View has to be used)) receives this URL parameter in an addi-

tional Startup-Plug parameter named e.g. 'parameter'. Because the

URL-parameter was added following the notation app..wdGetContext().currentContext

Element().setReceivedParameter(parameter);

Please let me know if that helps!

Best regards,

Karin

Former Member
0 Kudos

Hi Karin,

I just tried it out and it worked perfectly fine.

Thanks a lot.

Regards

Michael