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

Function SEGMENT_FTX 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 'SEGMENT_FTX'"Free Text.
EXPORTING
* I_QUAL_PAYMDETAILS = "
* I_V2_ZEILE = 33 "
* I_QUAL_V2 = "
* I_QUAL_KURZVZ = "
* I_QUAL_ADD_INFO = "Additional information
* I_TEXT1 = "First line
* I_TEXT2 = "Second line
* I_TEXT3 = "Third line
* I_TEXT4 = "Fourth line
* I_TEXT5 = "Fifth line
IMPORTING
E_RES = "
EXCEPTIONS
INVALID_INPUT = 1
IMPORTING Parameters details for SEGMENT_FTX
I_QUAL_PAYMDETAILS -
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_V2_ZEILE -
Data type: NUMC2Default: 33
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_QUAL_V2 -
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_QUAL_KURZVZ -
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_QUAL_ADD_INFO - Additional information
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXT1 - First line
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXT2 - Second line
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXT3 - Third line
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXT4 - Fourth line
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXT5 - Fifth line
Data type: COptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for SEGMENT_FTX
E_RES -
Data type: COptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
INVALID_INPUT -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for SEGMENT_FTX 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_res | TYPE C, " | |||
| lv_invalid_input | TYPE C, " | |||
| lv_i_qual_paymdetails | TYPE C, " | |||
| lv_i_v2_zeile | TYPE NUMC2, " 33 | |||
| lv_i_qual_v2 | TYPE C, " | |||
| lv_i_qual_kurzvz | TYPE C, " | |||
| lv_i_qual_add_info | TYPE C, " | |||
| lv_i_text1 | TYPE C, " | |||
| lv_i_text2 | TYPE C, " | |||
| lv_i_text3 | TYPE C, " | |||
| lv_i_text4 | TYPE C, " | |||
| lv_i_text5 | TYPE C. " |
|   CALL FUNCTION 'SEGMENT_FTX' "Free Text |
| EXPORTING | ||
| I_QUAL_PAYMDETAILS | = lv_i_qual_paymdetails | |
| I_V2_ZEILE | = lv_i_v2_zeile | |
| I_QUAL_V2 | = lv_i_qual_v2 | |
| I_QUAL_KURZVZ | = lv_i_qual_kurzvz | |
| I_QUAL_ADD_INFO | = lv_i_qual_add_info | |
| I_TEXT1 | = lv_i_text1 | |
| I_TEXT2 | = lv_i_text2 | |
| I_TEXT3 | = lv_i_text3 | |
| I_TEXT4 | = lv_i_text4 | |
| I_TEXT5 | = lv_i_text5 | |
| IMPORTING | ||
| E_RES | = lv_e_res | |
| EXCEPTIONS | ||
| INVALID_INPUT = 1 | ||
| . " SEGMENT_FTX | ||
ABAP code using 7.40 inline data declarations to call FM SEGMENT_FTX
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_v2_zeile) | = 33. | |||
Search for further information about these or an SAP related objects