SAP LOAN_DUNNING_PRINT Function Module for FI Dunning - Print Dunning Letter
LOAN_DUNNING_PRINT is a standard loan dunning print SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for FI Dunning - Print Dunning Letter 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 loan dunning print FM, simply by entering the name LOAN_DUNNING_PRINT into the relevant SAP transaction such as SE37 or SE38.
Function Group: FVD_DUNN
Program Name: SAPLFVD_DUNN
Main Program: SAPLFVD_DUNN
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function LOAN_DUNNING_PRINT 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 'LOAN_DUNNING_PRINT'"FI Dunning - Print Dunning Letter.
EXPORTING
I_MAHNV = "aktuelles Mahnverfahren
I_F150V = "Work fields
* I_F150D2 = "
I_MHNK = "Dunning Header
I_ITCPO = "Print Parameters
* I_UPDATE = ' ' "KZ: Echtdruck
* I_MOUT = ' ' "KZ: Nachrichten im Baustein ausgeben
* I_OFI = 'X' "
CHANGING
E_COMREQ = "Indicator: Commit Required
TABLES
T_MHND = "Dunning Lines
* T_FIMSG = "Log
EXCEPTIONS
PARAM_ERROR = 1 ACCNT_BLOCK = 2
IMPORTING Parameters details for LOAN_DUNNING_PRINT
I_MAHNV - aktuelles Mahnverfahren
Data type: MAHNVOptional: No
Call by Reference: No ( called with pass by value option)
I_F150V - Work fields
Data type: F150VOptional: No
Call by Reference: No ( called with pass by value option)
I_F150D2 -
Data type: F150D2Optional: Yes
Call by Reference: No ( called with pass by value option)
I_MHNK - Dunning Header
Data type: MHNKOptional: No
Call by Reference: No ( called with pass by value option)
I_ITCPO - Print Parameters
Data type: ITCPOOptional: No
Call by Reference: No ( called with pass by value option)
I_UPDATE - KZ: Echtdruck
Data type: CDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_MOUT - KZ: Nachrichten im Baustein ausgeben
Data type: BOOLE-BOOLEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_OFI -
Data type: BOOLE-BOOLEDefault: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)
CHANGING Parameters details for LOAN_DUNNING_PRINT
E_COMREQ - Indicator: Commit Required
Data type: BOOLE-BOOLEOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for LOAN_DUNNING_PRINT
T_MHND - Dunning Lines
Data type: MHNDOptional: No
Call by Reference: No ( called with pass by value option)
T_FIMSG - Log
Data type: FIMSGOptional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
PARAM_ERROR - Parameter Error
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ACCNT_BLOCK -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for LOAN_DUNNING_PRINT 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: | ||||
| lt_t_mhnd | TYPE STANDARD TABLE OF MHND, " | |||
| lv_i_mahnv | TYPE MAHNV, " | |||
| lv_e_comreq | TYPE BOOLE-BOOLE, " | |||
| lv_param_error | TYPE BOOLE, " | |||
| lv_i_f150v | TYPE F150V, " | |||
| lt_t_fimsg | TYPE STANDARD TABLE OF FIMSG, " | |||
| lv_accnt_block | TYPE FIMSG, " | |||
| lv_i_f150d2 | TYPE F150D2, " | |||
| lv_i_mhnk | TYPE MHNK, " | |||
| lv_i_itcpo | TYPE ITCPO, " | |||
| lv_i_update | TYPE C, " SPACE | |||
| lv_i_mout | TYPE BOOLE-BOOLE, " SPACE | |||
| lv_i_ofi | TYPE BOOLE-BOOLE. " 'X' |
|   CALL FUNCTION 'LOAN_DUNNING_PRINT' "FI Dunning - Print Dunning Letter |
| EXPORTING | ||
| I_MAHNV | = lv_i_mahnv | |
| I_F150V | = lv_i_f150v | |
| I_F150D2 | = lv_i_f150d2 | |
| I_MHNK | = lv_i_mhnk | |
| I_ITCPO | = lv_i_itcpo | |
| I_UPDATE | = lv_i_update | |
| I_MOUT | = lv_i_mout | |
| I_OFI | = lv_i_ofi | |
| CHANGING | ||
| E_COMREQ | = lv_e_comreq | |
| TABLES | ||
| T_MHND | = lt_t_mhnd | |
| T_FIMSG | = lt_t_fimsg | |
| EXCEPTIONS | ||
| PARAM_ERROR = 1 | ||
| ACCNT_BLOCK = 2 | ||
| . " LOAN_DUNNING_PRINT | ||
ABAP code using 7.40 inline data declarations to call FM LOAN_DUNNING_PRINT
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 BOOLE FROM BOOLE INTO @DATA(ld_e_comreq). | ||||
| DATA(ld_i_update) | = ' '. | |||
| "SELECT single BOOLE FROM BOOLE INTO @DATA(ld_i_mout). | ||||
| DATA(ld_i_mout) | = ' '. | |||
| "SELECT single BOOLE FROM BOOLE INTO @DATA(ld_i_ofi). | ||||
| DATA(ld_i_ofi) | = 'X'. | |||
Search for further information about these or an SAP related objects