cancel
Showing results for 
Search instead for 
Did you mean: 

How to get URL parameters and use it to set input field values

Former Member
0 Kudos

Hi Experts,

I was able to read url parameter through the HANDLEDEFAULT method of the window:

DATA: lt_url_parameters TYPE tihttpnvp.

wdevent->get_data(

EXPORTING

name = if_wd_application=>all_url_parameters

IMPORTING

value = lt_url_parameters ).

I can see in debug that the table contains all the read parameters.

What I need to know is how can I use that parameters to set automatically, for example, the default value of an inputfield of my wda.

Hope someone can provide me some hints.

Thanks in advance

ISC MI

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member188831
Contributor
0 Kudos

Hi

I hope you got that code from ...

http://help.sap.com/saphelp_nw70ehp1/helpdata/en/45/2233b60c21072ce10000000a155369/frameset.htm

i am trying the same palced the code in widnow plug in def..method.

but syntax error in fiel all_url_parameters is unknown.

any how the since code is working for you...

after this method got executed...

you will get the values into "l_url_parameters"

this works as an internal table which has 2 field Name and Value.

by using read table or by looping into wa you can fetch the values and map to your context.

all the best...

Regards,

Mahesh.Gattu

Regards,

Mahesh.Gattu

Edited by: Maheshkumar gattu on May 22, 2009 10:38 AM

Former Member
0 Kudos

Hi,

After fething the URL parameters you can bind them to some context attributes.

Those context attributes then can be bound to Input field.

This will help in getting propulating application parameters.

Regards

Manas Dua

Former Member
0 Kudos

HI,

1. Import your URL data into window

2. bind it to your window's context node and

3. map this context to your view's context node providing window controller is a used controller in you view.

Regards,

Srini Gollakaram.

Former Member
0 Kudos

The Context of the Component controller can be accessed through out the application, so you can read the url parameter and set the context attribute to which your input field is binded which makes the value default for the input field in the runtime.

Regards,

Trikanth