SAP BM_F4_ASS_VARI Function Module for AFW: Search Help Exit for Portfolio Hierarchy ID
BM_F4_ASS_VARI is a standard bm f4 ass vari SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for AFW: Search Help Exit for Portfolio Hierarchy ID 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 bm f4 ass vari FM, simply by entering the name BM_F4_ASS_VARI into the relevant SAP transaction such as SE37 or SE38.
Function Group: AFWBM_SERVICES
Program Name: SAPLAFWBM_SERVICES
Main Program: SAPLAFWBM_SERVICES
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function BM_F4_ASS_VARI 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 'BM_F4_ASS_VARI'"AFW: Search Help Exit for Portfolio Hierarchy ID.
EXPORTING
* I_PROGNAME = SY-CPROG "ABAP Program Name
* I_DYNPRO_NUMBER = SY-DYNNR "CHAR04 Data Element for SYST
I_FIELDNAME_VIEW = "Field Name of View (Parameter)
I_FIELDNAME_PH = "Field Name of Portfolio Hierarchy (Parameter)
IMPORTING
E_ASS_VARI = "Assignment Variant
EXCEPTIONS
INTERNAL_ERROR = 1
IMPORTING Parameters details for BM_F4_ASS_VARI
I_PROGNAME - ABAP Program Name
Data type: PROGNAMEDefault: SY-CPROG
Optional: Yes
Call by Reference: Yes
I_DYNPRO_NUMBER - CHAR04 Data Element for SYST
Data type: D020S-DNUMDefault: SY-DYNNR
Optional: Yes
Call by Reference: Yes
I_FIELDNAME_VIEW - Field Name of View (Parameter)
Data type: DYNFNAMOptional: No
Call by Reference: Yes
I_FIELDNAME_PH - Field Name of Portfolio Hierarchy (Parameter)
Data type: DYNFNAMOptional: No
Call by Reference: Yes
EXPORTING Parameters details for BM_F4_ASS_VARI
E_ASS_VARI - Assignment Variant
Data type: AFWBM_ASSVARIOptional: No
Call by Reference: Yes
EXCEPTIONS details
INTERNAL_ERROR -
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for BM_F4_ASS_VARI 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_e_ass_vari | TYPE AFWBM_ASSVARI, " | |||
| lv_i_progname | TYPE PROGNAME, " SY-CPROG | |||
| lv_internal_error | TYPE PROGNAME, " | |||
| lv_i_dynpro_number | TYPE D020S-DNUM, " SY-DYNNR | |||
| lv_i_fieldname_view | TYPE DYNFNAM, " | |||
| lv_i_fieldname_ph | TYPE DYNFNAM. " |
|   CALL FUNCTION 'BM_F4_ASS_VARI' "AFW: Search Help Exit for Portfolio Hierarchy ID |
| EXPORTING | ||
| I_PROGNAME | = lv_i_progname | |
| I_DYNPRO_NUMBER | = lv_i_dynpro_number | |
| I_FIELDNAME_VIEW | = lv_i_fieldname_view | |
| I_FIELDNAME_PH | = lv_i_fieldname_ph | |
| IMPORTING | ||
| E_ASS_VARI | = lv_e_ass_vari | |
| EXCEPTIONS | ||
| INTERNAL_ERROR = 1 | ||
| . " BM_F4_ASS_VARI | ||
ABAP code using 7.40 inline data declarations to call FM BM_F4_ASS_VARI
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.| DATA(ld_i_progname) | = SY-CPROG. | |||
| "SELECT single DNUM FROM D020S INTO @DATA(ld_i_dynpro_number). | ||||
| DATA(ld_i_dynpro_number) | = SY-DYNNR. | |||
Search for further information about these or an SAP related objects