2006 Oct 02 10:06 PM
Hi, I know it's been covered way too much, but I can't seem to make sense of it. I have a report list that opens up another list when a line is clicked. There is no initial selection screen. When a user selects exit on the 2nd list I want to return back to the basic list.
What's the easiest/best way to do this simple task?!
AT USER-COMMAND.
CASE SY-UCOMM.
WHEN 'SELALL'.
DO.
READ LINE SY-INDEX FIELD VALUE CHECK1.
CHECK1 = 'X'.
MODIFY LINE SY-INDEX FIELD VALUE CHECK1.
IF SY-SUBRC <> 0. EXIT. ENDIF.
ENDDO.
WHEN 'REMALL'.
DO.
READ LINE SY-INDEX FIELD VALUE CHECK1.
CHECK1 = SPACE.
MODIFY LINE SY-INDEX FIELD VALUE CHECK1.
IF SY-SUBRC <> 0. EXIT. ENDIF.
ENDDO.
WHEN 'EXIT'.
SY-LSIND = 1.
ENDCASE.
2006 Oct 02 10:49 PM
Hi,
Try this..
write: / sy-lsind.
start-of-selection.
SET PF-STATUS 'TEST1'.
AT USER-COMMAND.
If sy-ucomm = 'DISPLAY'.
write: / sy-lsind.
endif.
<b>IF SY-UCOMM = 'EXIT'.
if sy-lsind > 1.
SY-LSIND = 0.
endif.
endif.</b>
Thanks,
Naren
Hi, I know it's been covered way too much, but I can't seem to make sense of it. I have a report list that opens up another list when a line is clicked. There is no initial selection screen. When a user selects exit on the 2nd list I want to return back to the basic list.
What's the easiest/best way to do this simple task?!
AT USER-COMMAND.
CASE SY-UCOMM.
WHEN 'SELALL'.
DO.
READ LINE SY-INDEX FIELD VALUE CHECK1.
CHECK1 = 'X'.
MODIFY LINE SY-INDEX FIELD VALUE CHECK1.
IF SY-SUBRC <> 0. EXIT. ENDIF.
ENDDO.
WHEN 'REMALL'.
DO.
READ LINE SY-INDEX FIELD VALUE CHECK1.
CHECK1 = SPACE.
MODIFY LINE SY-INDEX FIELD VALUE CHECK1.
IF SY-SUBRC <> 0. EXIT. ENDIF.
ENDDO.
WHEN 'EXIT'.
SY-LSIND = 1.
ENDCASE.
2006 Oct 02 10:49 PM
Hi,
Try this..
write: / sy-lsind.
start-of-selection.
SET PF-STATUS 'TEST1'.
AT USER-COMMAND.
If sy-ucomm = 'DISPLAY'.
write: / sy-lsind.
endif.
<b>IF SY-UCOMM = 'EXIT'.
if sy-lsind > 1.
SY-LSIND = 0.
endif.
endif.</b>
Thanks,
Naren
2006 Oct 02 10:50 PM
Found the answer here at the below url. Seems to me it should be easier than this.
Svetlin Rusev
Posts: 591
Questions: 11
Forum Points: 1,060
Registered: 3/22/05
Re: Basic List
Posted: Nov 8, 2005 9:32 AM Reply E-mail this post
Hi,
After pressing your button use FM 'SAPGUI_SET_FUNCTIONCODE' and set a new function code 'BACK'.
Svetlin
2006 Oct 02 10:52 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |