2010 Aug 11 10:46 AM
My requirement is that 1 button already has been added in the menu bar od ALV. Now, when that push button is clicked, there will be 2 more pushbutton should appear on the menu bar of ALV.
How can achieve this?
You can have the menu in the initial stage itself. By default, disable it. If the user command is 'PUSH', enable those menu functions.
Cheers
Sujay
2010 Aug 11 11:20 AM
It's simple :
set handler for toolbar and user_command.
when 'PUSH1'.
call method :
METHOD handle_toolbar.
DATA: ls_bar TYPE stb_button.
CLEAR ls_bar.
*add user button to the ALV toolbar
MOVE 'TRANS' TO ls_bar-function.
MOVE text-004 TO ls_bar-quickinfo.
MOVE icon_transport TO ls_bar-icon.
MOVE text-005 TO ls_bar-text.
CLEAR ls_bar-disabled.
APPEND ls_bar TO e_object->mt_toolbar.
2010 Aug 11 11:26 AM
I am getting dump while doing this.
dump is Access via 'NULL' object reference not possible.
2010 Aug 11 11:29 AM
You can have the menu in the initial stage itself. By default, disable it. If the user command is 'PUSH', enable those menu functions.
Cheers
Sujay
2010 Aug 12 5:47 AM
2010 Aug 19 1:31 PM
| User | Count |
|---|---|
| 6 | |
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |