cancel
Showing results for 
Search instead for 
Did you mean: 

Can we pass parameters in querystring of the webdynpro application?

Former Member
0 Kudos

Hello Everybody,

I am developing one application which requires some parameters to be passed when we run that application in browser. I want to invoke my webdynpro application from already developed website. I can put url of my webdynpro application in my website and i can invoke from there.

But i also want to pass some parameters to dynpro application through querystring when i invoke it from my website.

So any mathods or procedure to do this?

Thanks in Advance,

Bhavik

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi all,

Thanks for your reply, but actually i want to recieve those parameters in webdynpro and these parameters have to be passed from the website where my dynpro application's url resides. This website passes user information by appending to the url of dynpro application. Now i want to get this user info. in my webdynpro application.

Regards,

Bhavik

Former Member
0 Kudos

Hi,

The following would be helpful

WDWebContextAdapter.getWebContextAdapter().getRequestParameter(<param name>);

regards

Noufal

Former Member
0 Kudos

Hi Bhavik,

One simple way is to define import parameters in the Default plug.

Lets say you have defined a parameter with name "param1", then it should be passed to the url as app.param1=<value>.

This value is directly accessible from the Default Plug implementation in the Interface view, now you could store this into a component, for access by other units.

Regards,

Pavan

Former Member
0 Kudos

Correct, and the "app." prefix is not needed anymore (IIRC).

Armin

Former Member
0 Kudos

Hi All!

How do i access the parameter ? after this ?

I am not quite sure how i can gain acces to the value afterwards in my view.

Kind Regards

Ronni Hostrup

Former Member
0 Kudos

Sorry I couldn't get your question. Please explain better

Former Member
0 Kudos

Hi Again!

Ok i will try to explain again

I have added a parameter to the Default plug, and in the event handler for this, i get acces to the parameter, but how do i use this value in my application.

Regards Ronni Hostrup

Former Member
0 Kudos

Just create a context attribute in the controller and set it from the interface view.

wdThis.wdGet<component>Controller().wdGetContext().currentContextElement().set<attribute>()

Hope that would help you.

Regards

Noufal

Former Member
0 Kudos

Noufal!

Thanks alot!

this solved the problem!!

Kind Regards

Ronni Hostrup

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Bhavik ,

You can pass parameters to a webdynpro application like you pass parameter to any other web applications.

I mean URL ?Param1=Value1&Param2=Value2

Regards, Anilkumar

Former Member
0 Kudos

Hi,

Hope the following code would be helpful

WDDeployableObjectPart deployableObjectPart=WDDeployableObject.getDeployableObjectPart(deployableObjectName,<application name>,WDDeployableObjectPartType.APPLICATION);

String urlToTarget=WDURLGenerator.getApplicationURL(deployableObjectPart);

No you can append parameters to the url as given in the above post.

Kindly do close the post once you have recived the reply

With best regards

Noufal