SAP ISH_SET_NEXT_SCREEN Function Module for IS-H: Screen sequence control: set the next screen acc. to TN00D
ISH_SET_NEXT_SCREEN is a standard ish set next screen SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for IS-H: Screen sequence control: set the next screen acc. to TN00D processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for ish set next screen FM, simply by entering the name ISH_SET_NEXT_SCREEN into the relevant SAP transaction such as SE37 or SE38.
Function Group: N006
Program Name: SAPLN006
Main Program: SAPLN006
Appliation area: N
Release date: 08-Jun-1994
Mode(Normal, Remote etc): Normal Function Module
Update:

Function ISH_SET_NEXT_SCREEN pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'ISH_SET_NEXT_SCREEN'"IS-H: Screen sequence control: set the next screen acc. to TN00D.
EXPORTING
* ACT_TCODE = SY-TCODE "Current transaction code ->F2
* EINRI = '* ' "Institution (or: ****) ->F2
* EXTP_NAM = SY-CPROG "Program name for external perform (SAVE etc.)
* FCODE = ' ' "Control code for next screen: BACK, SAVE ->F2
* GOTO_DYNNR = SY-DYNNR "Target screen for FCode GOTO ->F2
* LEAVE_TCODE = ' ' "Transaction code for FCode LNOR or LSKI ->F2
* SAVE_TO_MENU = ' ' "ID that branch to menu after SAVE ->F2
* SCREEN_CALLED = ' ' "ID branch screen (' ' or 'X') ->F2
* I_TITLE = ' ' "Title Row
IMPORTING
FCODE = "Control code for next screen: BACK, SAVE ->F2
NEXT_DYNNR = "New screen number (information only) ->F2
EXCEPTIONS
DTAB_READ_ERROR = 1 INIT_ERROR = 2
IMPORTING Parameters details for ISH_SET_NEXT_SCREEN
ACT_TCODE - Current transaction code ->F2
Data type: SY-TCODEDefault: SY-TCODE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EINRI - Institution (or: ****) ->F2
Data type: TN01-EINRIDefault: '* '
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXTP_NAM - Program name for external perform (SAVE etc.)
Data type: SY-CPROGDefault: SY-CPROG
Optional: Yes
Call by Reference: No ( called with pass by value option)
FCODE - Control code for next screen: BACK, SAVE ->F2
Data type: SY-UCOMMDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
GOTO_DYNNR - Target screen for FCode GOTO ->F2
Data type: RNDYN-DYNNRDefault: SY-DYNNR
Optional: Yes
Call by Reference: No ( called with pass by value option)
LEAVE_TCODE - Transaction code for FCode LNOR or LSKI ->F2
Data type: SY-TCODEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
SAVE_TO_MENU - ID that branch to menu after SAVE ->F2
Data type: NPDOK-XFELDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
SCREEN_CALLED - ID branch screen (' ' or 'X') ->F2
Data type: NPDOK-XFELDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_TITLE - Title Row
Data type: SY-TITLEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for ISH_SET_NEXT_SCREEN
FCODE - Control code for next screen: BACK, SAVE ->F2
Data type: SY-UCOMMOptional: No
Call by Reference: No ( called with pass by value option)
NEXT_DYNNR - New screen number (information only) ->F2
Data type: SY-DYNNROptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
DTAB_READ_ERROR - Error in DTAB read (internal error!) ->F2
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INIT_ERROR - Error when initializing DTAB frim TN00D ->F2
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for ISH_SET_NEXT_SCREEN Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.| DATA: | ||||
| lv_fcode | TYPE SY-UCOMM, " | |||
| lv_act_tcode | TYPE SY-TCODE, " SY-TCODE | |||
| lv_dtab_read_error | TYPE SY, " | |||
| lv_einri | TYPE TN01-EINRI, " '* ' | |||
| lv_init_error | TYPE TN01, " | |||
| lv_next_dynnr | TYPE SY-DYNNR, " | |||
| lv_extp_nam | TYPE SY-CPROG, " SY-CPROG | |||
| lv_fcode | TYPE SY-UCOMM, " SPACE | |||
| lv_goto_dynnr | TYPE RNDYN-DYNNR, " SY-DYNNR | |||
| lv_leave_tcode | TYPE SY-TCODE, " SPACE | |||
| lv_save_to_menu | TYPE NPDOK-XFELD, " SPACE | |||
| lv_screen_called | TYPE NPDOK-XFELD, " SPACE | |||
| lv_i_title | TYPE SY-TITLE. " SPACE |
|   CALL FUNCTION 'ISH_SET_NEXT_SCREEN' "IS-H: Screen sequence control: set the next screen acc. to TN00D |
| EXPORTING | ||
| ACT_TCODE | = lv_act_tcode | |
| EINRI | = lv_einri | |
| EXTP_NAM | = lv_extp_nam | |
| FCODE | = lv_fcode | |
| GOTO_DYNNR | = lv_goto_dynnr | |
| LEAVE_TCODE | = lv_leave_tcode | |
| SAVE_TO_MENU | = lv_save_to_menu | |
| SCREEN_CALLED | = lv_screen_called | |
| I_TITLE | = lv_i_title | |
| IMPORTING | ||
| FCODE | = lv_fcode | |
| NEXT_DYNNR | = lv_next_dynnr | |
| EXCEPTIONS | ||
| DTAB_READ_ERROR = 1 | ||
| INIT_ERROR = 2 | ||
| . " ISH_SET_NEXT_SCREEN | ||
ABAP code using 7.40 inline data declarations to call FM ISH_SET_NEXT_SCREEN
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.| "SELECT single UCOMM FROM SY INTO @DATA(ld_fcode). | ||||
| "SELECT single TCODE FROM SY INTO @DATA(ld_act_tcode). | ||||
| DATA(ld_act_tcode) | = SY-TCODE. | |||
| "SELECT single EINRI FROM TN01 INTO @DATA(ld_einri). | ||||
| DATA(ld_einri) | = '* '. | |||
| "SELECT single DYNNR FROM SY INTO @DATA(ld_next_dynnr). | ||||
| "SELECT single CPROG FROM SY INTO @DATA(ld_extp_nam). | ||||
| DATA(ld_extp_nam) | = SY-CPROG. | |||
| "SELECT single UCOMM FROM SY INTO @DATA(ld_fcode). | ||||
| DATA(ld_fcode) | = ' '. | |||
| "SELECT single DYNNR FROM RNDYN INTO @DATA(ld_goto_dynnr). | ||||
| DATA(ld_goto_dynnr) | = SY-DYNNR. | |||
| "SELECT single TCODE FROM SY INTO @DATA(ld_leave_tcode). | ||||
| DATA(ld_leave_tcode) | = ' '. | |||
| "SELECT single XFELD FROM NPDOK INTO @DATA(ld_save_to_menu). | ||||
| DATA(ld_save_to_menu) | = ' '. | |||
| "SELECT single XFELD FROM NPDOK INTO @DATA(ld_screen_called). | ||||
| DATA(ld_screen_called) | = ' '. | |||
| "SELECT single TITLE FROM SY INTO @DATA(ld_i_title). | ||||
| DATA(ld_i_title) | = ' '. | |||
Search for further information about these or an SAP related objects