on 11-18-2008 9:54 AM
Hello,
Can I assign same acction to two different buttons and inside the event get to know from which button the action is fired ?
Regards,
Thanks guys, will try this out....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shah,
Its possible. Just go to the action handler for the button & read the attribute ID of the WDEVENT which is passed by the framework. This id will contain the id of the button which triggered the event. Consider the code fragment below:
method ONACTIONACTION .
DATA: lv_button_name type string.
lv_button_name = wdevent->get_string( name = 'ID' ).
endmethod.
At the end of execution lv_button_name will have the ID of the button which triggered the event.
Regards,
Uday
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello ,
This can be acheived by using the method
DATA: lv_element_id type string .
WDEVENT->GET_STRING ( EXPORTING NAME = 'ID'
IMPORTING
value = lv_element_id . )
both button will have the diffferent id .
Regards
Vivek
PS: please provide the points if answer is helpful .
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shah,
you cann't create same action to two different buttons.it will give error saying that "There is already an action named ACTION".So it is not possible.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.