on 04-15-2009 3:50 AM
Hi:
I have a problem to solve about web dynpro for abap.
I create a table and the first column is a LINK_TO_BUTTON(Function LIKE BBS),if there are 6 rows data ,when i click the link_to_button of 1 row in 6,I want to konw which row i have clicked ,
so,how to do it? wish to give me some advice.
Thanks in advance.
Edited by: gmasfk on Apr 15, 2009 4:56 AM
Hi,
Use can put following code in the ONACTION of LINK_TO_BUTTON.
method ONACTIONONLINKTOBUTTON .
data: lr_element type ref to if_wd_context_element,
lv_index type i.
lr_element = wdevent->get_context_element( name = 'CONTEXT_ELEMENT' ).
lv_index = lr_element->get_index( ).
Now lv_index will contain the table row number in which the button was triggered.
I hope it helps.
Regards,
Rohit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ALEX:
Thanks for your reply,quikily.
I don't understand the ' "pass ui parameters" check box ',where it is?
when i get the name of the element , it always display the first row whether you click any row.
the effect i want to achieve is topic list,when i click current topic ,it will jump to a new window,
the data will be displayed by topic.
I'm Sorry to give you trouble.
kind regards,
gmasfk
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi gmasfk,
when you create an action for the element for the first time, you get a pop up window where you mention the action name, there you will have a check box to transfer ui events, or you can go to the actions tab and click the button present in the last column of the action and change it.... or you can even try getting the lead selection value
---regards,
Alex B Justin
hi,
when you create the action for the link, check the "pass ui parameters" check box. this will give you reference to class cl_wd_event, with which you can get the name of the element and other properties and use it.
---regards,
Alex B Justin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.