SAP RK_F4_ALLOCATION_CYCLE Function Module for
RK_F4_ALLOCATION_CYCLE is a standard rk f4 allocation cycle SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 rk f4 allocation cycle FM, simply by entering the name RK_F4_ALLOCATION_CYCLE into the relevant SAP transaction such as SE37 or SE38.
Function Group: K4AL
Program Name: SAPLK4AL
Main Program: SAPLK4AL
Appliation area: K
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function RK_F4_ALLOCATION_CYCLE 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 'RK_F4_ALLOCATION_CYCLE'".
EXPORTING
* ALART = ' ' "Allocation Type
* LIST_TITLE = ' ' "Window Title Row
* MAX_SDATE = 00000000 "Latest Starting Date of Cycle
* MIN_EDATE = 00000000 "Minimum Completion Date of Cycle
* ORIGINX = 0 "X-Coordinate of Window Left Top Corner
* ORIGINY = 0 "Y-Coordinate of Window Left Top Corner
* SDATE = 00000000 "Cycle Starting Date
* SHOW_ONE_ENTRY = ' ' "Indicator: No List for Only One Value
* TABLE = ' ' "Cycle Table
* SEG_REVERS = ' ' "
* CHOOSEN = ' ' "
* APPL = ' ' "Application
* CYCLE = ' ' "Cycle
* DISPLAY = ' ' "Indicator: List in Display Mode Only
* FIX_CYCLE = ' ' "Indicator: Cycle Can Be Changed
* FIX_GROUP = ' ' "Indicator: Organizational Unit Can Be Changed
* FIX_SDATE = ' ' "Indicator: Date Can Be Changed
* GROUP = ' ' "Organizational Unit (Ledger, CO Area, ERKSR, ...)
* IPKNZ = ' ' "Actual(Plan Indicator
IMPORTING
EX_CYCLE = "Cycle (Short Form w/o Organizational Unit)
EX_GROUP = "Organizational unit
SDATE = "Cycle Starting Date
TABLE = "Cycle Table
TABLES
* DYNPFIELDS = "
EXCEPTIONS
NOTHING_SELECTED = 1 NO_CYCLE = 2
IMPORTING Parameters details for RK_F4_ALLOCATION_CYCLE
ALART - Allocation Type
Data type: T811C-ALARTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
LIST_TITLE - Window Title Row
Data type: SY-TITLEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
MAX_SDATE - Latest Starting Date of Cycle
Data type: T811C-SDATEDefault: 00000000
Optional: Yes
Call by Reference: No ( called with pass by value option)
MIN_EDATE - Minimum Completion Date of Cycle
Data type: T811C-EDATEDefault: 00000000
Optional: Yes
Call by Reference: No ( called with pass by value option)
ORIGINX - X-Coordinate of Window Left Top Corner
Data type: SY-WINX1Optional: Yes
Call by Reference: No ( called with pass by value option)
ORIGINY - Y-Coordinate of Window Left Top Corner
Data type: SY-WINY1Optional: Yes
Call by Reference: No ( called with pass by value option)
SDATE - Cycle Starting Date
Data type: T811C-SDATEDefault: 00000000
Optional: Yes
Call by Reference: No ( called with pass by value option)
SHOW_ONE_ENTRY - Indicator: No List for Only One Value
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
TABLE - Cycle Table
Data type: T811C-TABDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
SEG_REVERS -
Data type: RKGA2U2-SEG_REVERSDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
CHOOSEN -
Data type: DYNPREAD-FIELDNAMEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
APPL - Application
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
CYCLE - Cycle
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
DISPLAY - Indicator: List in Display Mode Only
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FIX_CYCLE - Indicator: Cycle Can Be Changed
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FIX_GROUP - Indicator: Organizational Unit Can Be Changed
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FIX_SDATE - Indicator: Date Can Be Changed
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
GROUP - Organizational Unit (Ledger, CO Area, ERKSR, ...)
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IPKNZ - Actual(Plan Indicator
Data type: T811C-IPKNZDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for RK_F4_ALLOCATION_CYCLE
EX_CYCLE - Cycle (Short Form w/o Organizational Unit)
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
EX_GROUP - Organizational unit
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
SDATE - Cycle Starting Date
Data type: T811C-SDATEOptional: No
Call by Reference: No ( called with pass by value option)
TABLE - Cycle Table
Data type: T811C-TABOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for RK_F4_ALLOCATION_CYCLE
DYNPFIELDS -
Data type: DYNPREADOptional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NOTHING_SELECTED - No Selection Made
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
NO_CYCLE - No Cycle Found
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for RK_F4_ALLOCATION_CYCLE 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_alart | TYPE T811C-ALART, " SPACE | |||
| lv_ex_cycle | TYPE T811C, " | |||
| lt_dynpfields | TYPE STANDARD TABLE OF DYNPREAD, " | |||
| lv_nothing_selected | TYPE DYNPREAD, " | |||
| lv_list_title | TYPE SY-TITLE, " SPACE | |||
| lv_max_sdate | TYPE T811C-SDATE, " 00000000 | |||
| lv_min_edate | TYPE T811C-EDATE, " 00000000 | |||
| lv_originx | TYPE SY-WINX1, " 0 | |||
| lv_originy | TYPE SY-WINY1, " 0 | |||
| lv_sdate | TYPE T811C-SDATE, " 00000000 | |||
| lv_show_one_entry | TYPE T811C, " SPACE | |||
| lv_table | TYPE T811C-TAB, " SPACE | |||
| lv_seg_revers | TYPE RKGA2U2-SEG_REVERS, " SPACE | |||
| lv_choosen | TYPE DYNPREAD-FIELDNAME, " SPACE | |||
| lv_appl | TYPE DYNPREAD, " SPACE | |||
| lv_ex_group | TYPE DYNPREAD, " | |||
| lv_no_cycle | TYPE DYNPREAD, " | |||
| lv_cycle | TYPE DYNPREAD, " SPACE | |||
| lv_sdate | TYPE T811C-SDATE, " | |||
| lv_table | TYPE T811C-TAB, " | |||
| lv_display | TYPE T811C, " SPACE | |||
| lv_fix_cycle | TYPE T811C, " SPACE | |||
| lv_fix_group | TYPE T811C, " SPACE | |||
| lv_fix_sdate | TYPE T811C, " SPACE | |||
| lv_group | TYPE T811C, " SPACE | |||
| lv_ipknz | TYPE T811C-IPKNZ. " SPACE |
|   CALL FUNCTION 'RK_F4_ALLOCATION_CYCLE' " |
| EXPORTING | ||
| ALART | = lv_alart | |
| LIST_TITLE | = lv_list_title | |
| MAX_SDATE | = lv_max_sdate | |
| MIN_EDATE | = lv_min_edate | |
| ORIGINX | = lv_originx | |
| ORIGINY | = lv_originy | |
| SDATE | = lv_sdate | |
| SHOW_ONE_ENTRY | = lv_show_one_entry | |
| TABLE | = lv_table | |
| SEG_REVERS | = lv_seg_revers | |
| CHOOSEN | = lv_choosen | |
| APPL | = lv_appl | |
| CYCLE | = lv_cycle | |
| DISPLAY | = lv_display | |
| FIX_CYCLE | = lv_fix_cycle | |
| FIX_GROUP | = lv_fix_group | |
| FIX_SDATE | = lv_fix_sdate | |
| GROUP | = lv_group | |
| IPKNZ | = lv_ipknz | |
| IMPORTING | ||
| EX_CYCLE | = lv_ex_cycle | |
| EX_GROUP | = lv_ex_group | |
| SDATE | = lv_sdate | |
| TABLE | = lv_table | |
| TABLES | ||
| DYNPFIELDS | = lt_dynpfields | |
| EXCEPTIONS | ||
| NOTHING_SELECTED = 1 | ||
| NO_CYCLE = 2 | ||
| . " RK_F4_ALLOCATION_CYCLE | ||
ABAP code using 7.40 inline data declarations to call FM RK_F4_ALLOCATION_CYCLE
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 ALART FROM T811C INTO @DATA(ld_alart). | ||||
| DATA(ld_alart) | = ' '. | |||
| "SELECT single TITLE FROM SY INTO @DATA(ld_list_title). | ||||
| DATA(ld_list_title) | = ' '. | |||
| "SELECT single SDATE FROM T811C INTO @DATA(ld_max_sdate). | ||||
| DATA(ld_max_sdate) | = 00000000. | |||
| "SELECT single EDATE FROM T811C INTO @DATA(ld_min_edate). | ||||
| DATA(ld_min_edate) | = 00000000. | |||
| "SELECT single WINX1 FROM SY INTO @DATA(ld_originx). | ||||
| "SELECT single WINY1 FROM SY INTO @DATA(ld_originy). | ||||
| "SELECT single SDATE FROM T811C INTO @DATA(ld_sdate). | ||||
| DATA(ld_sdate) | = 00000000. | |||
| DATA(ld_show_one_entry) | = ' '. | |||
| "SELECT single TAB FROM T811C INTO @DATA(ld_table). | ||||
| DATA(ld_table) | = ' '. | |||
| "SELECT single SEG_REVERS FROM RKGA2U2 INTO @DATA(ld_seg_revers). | ||||
| DATA(ld_seg_revers) | = ' '. | |||
| "SELECT single FIELDNAME FROM DYNPREAD INTO @DATA(ld_choosen). | ||||
| DATA(ld_choosen) | = ' '. | |||
| DATA(ld_appl) | = ' '. | |||
| DATA(ld_cycle) | = ' '. | |||
| "SELECT single SDATE FROM T811C INTO @DATA(ld_sdate). | ||||
| "SELECT single TAB FROM T811C INTO @DATA(ld_table). | ||||
| DATA(ld_display) | = ' '. | |||
| DATA(ld_fix_cycle) | = ' '. | |||
| DATA(ld_fix_group) | = ' '. | |||
| DATA(ld_fix_sdate) | = ' '. | |||
| DATA(ld_group) | = ' '. | |||
| "SELECT single IPKNZ FROM T811C INTO @DATA(ld_ipknz). | ||||
| DATA(ld_ipknz) | = ' '. | |||
Search for further information about these or an SAP related objects