cancel
Showing results for 
Search instead for 
Did you mean: 

Component Usage

Former Member
0 Kudos

Hi,

I have an WDA with a OBJECTDATAPROVIDER / Explorer View component usage. This view is been embedded into a container. The Web Dynpro works fine displaying the org. group infomation with list of employees.When user clicks on the PERNR i need to capture the value and use it. Could you pls let me know the steps involved.

Thanks,

Kumar.

Accepted Solutions (0)

Answers (1)

Answers (1)

ashish_shah
Contributor
0 Kudos

Hi Kumar,

Can you provide the name of the main WD Component? and the component that it calls?

Regards,

Ashish Shah

Former Member
0 Kudos

Hi,

My main dypro component is Z**** in which am using the component OBJECTDATAPROVIDER. I have embeded one of the view 'Explorer' of Objectdataprovider in a container of my z*** component view in order to display a list of employees under manager. My question is once the list is displayed how to capture the PERNR tht a user selects.

Thanks,

Kumar

ashish_shah
Contributor
0 Kudos

Hi Kumar,

I cant see the component OBJECTDATAPROVIDER in my System - this seems to be part of some business package.

Can you explain your problem technically ?

regards,

Ashish Shah

Former Member
0 Kudos

Hi ashish,

For example i have two different web dynpro application say wd1 and wd2. In WD2 i am using one of the view (ALV) of wd1 and displed the ALV in wd2. Here in WD2 am selecting one of the row which containts pernr . I am looking for the pernr to be capture in order to disply some more info. for WD2 application.

Thanks,

Kumar

ashish_shah
Contributor
0 Kudos

Hi Kumar,

You can create a method in component controller and make it interface method.

Add an importing parameter of the type pernr in this method.

This is your called component.

Now in your ALV component you need to implement ALV LEAD SELECTION EVENT. Read the lead selected value and pass to the calling components interface method.

You can refer to this document :

[ALV Events in WDA|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/101df93f-4b5c-2910-14aa-9eb0338c2110?quicklink=index&overridelayout=true]

Regards,

Ashish Shah

ashish_shah
Contributor
0 Kudos

Hi Kumar,

You can implement An event handler to listen / react to ON lead selection event of ALV.

In that Event handler method add an importing parameter called R_PARAM of type ref to IF_SALV_WD_TABLE_CLICK.

 
  FIELD-SYMBOLS: <l_value>        TYPE        ANY.
  DATA l_index                    TYPE        i.

* read selected attribute index and value
  l_index  = r_param->index.
  ASSIGN r_param->value->* TO <l_value>.

this way you will get the lead selection index of the ALV table and then you can read your node using this index.

 
  lo_el_element = lo_nd_element->get_element( index = l_index ).

Let me know if you still face problem after this.

regards,

Ashish Shah

ashish_shah
Contributor
0 Kudos

Hi Kumar,

If your problem is solved , plase award points and close the thread.

Regards,

Ashish Shah