SAP RH_EDIT_NAME Function Module for Formatting of the name and the name elements









RH_EDIT_NAME is a standard rh edit name SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Formatting of the name and the name elements 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 rh edit name FM, simply by entering the name RH_EDIT_NAME into the relevant SAP transaction such as SE37 or SE38.

Function Group: RHNA
Program Name: SAPLRHNA
Main Program:
Appliation area: H
Release date: 11-Feb-1994
Mode(Normal, Remote etc): Normal Function Module
Update:



Function RH_EDIT_NAME 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 'RH_EDIT_NAME'"Formatting of the name and the name elements
EXPORTING
* ADDRESSINFTY = ' ' "Address data
FORMAT = "Formated for editing
* NAMEINFTY = ' ' "Info type 1034 for name editing
NATION = "Nation not documented
OBJECTINFTY = "Object data documented
* OTHERINFTY = ' ' "Optional data documented

IMPORTING
NAMETEXT = "Edited text

EXCEPTIONS
FORMAT_FOR_NATION_NOT_FOUND = 1
.



IMPORTING Parameters details for RH_EDIT_NAME

ADDRESSINFTY - Address data

Data type: P1028
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

FORMAT - Formated for editing

Data type: T777N-FORMT
Optional: No
Call by Reference: No ( called with pass by value option)

NAMEINFTY - Info type 1034 for name editing

Data type: P1034
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

NATION - Nation not documented

Data type: T777N-NATIO
Optional: No
Call by Reference: No ( called with pass by value option)

OBJECTINFTY - Object data documented

Data type: OBJEC
Optional: No
Call by Reference: No ( called with pass by value option)

OTHERINFTY - Optional data documented

Data type: WPLOG
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for RH_EDIT_NAME

NAMETEXT - Edited text

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

FORMAT_FOR_NATION_NOT_FOUND - Format for given nation not in T777N

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for RH_EDIT_NAME 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_nametext  TYPE STRING, "   
lv_addressinfty  TYPE P1028, "   ' '
lv_format_for_nation_not_found  TYPE P1028, "   
lv_format  TYPE T777N-FORMT, "   
lv_nameinfty  TYPE P1034, "   ' '
lv_nation  TYPE T777N-NATIO, "   
lv_objectinfty  TYPE OBJEC, "   
lv_otherinfty  TYPE WPLOG. "   ' '

  CALL FUNCTION 'RH_EDIT_NAME'  "Formatting of the name and the name elements
    EXPORTING
         ADDRESSINFTY = lv_addressinfty
         FORMAT = lv_format
         NAMEINFTY = lv_nameinfty
         NATION = lv_nation
         OBJECTINFTY = lv_objectinfty
         OTHERINFTY = lv_otherinfty
    IMPORTING
         NAMETEXT = lv_nametext
    EXCEPTIONS
        FORMAT_FOR_NATION_NOT_FOUND = 1
. " RH_EDIT_NAME




ABAP code using 7.40 inline data declarations to call FM RH_EDIT_NAME

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_addressinfty) = ' '.
 
 
"SELECT single FORMT FROM T777N INTO @DATA(ld_format).
 
DATA(ld_nameinfty) = ' '.
 
"SELECT single NATIO FROM T777N INTO @DATA(ld_nation).
 
 
DATA(ld_otherinfty) = ' '.
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!