SAP SOLAR_TEMPLATE_CREATE Function Module for









SOLAR_TEMPLATE_CREATE is a standard solar template create 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 solar template create FM, simply by entering the name SOLAR_TEMPLATE_CREATE into the relevant SAP transaction such as SE37 or SE38.

Function Group: SADOC
Program Name: SAPLSADOC
Main Program: SAPLSADOC
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function SOLAR_TEMPLATE_CREATE 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 'SOLAR_TEMPLATE_CREATE'"
EXPORTING
I_TYPE = "Content Type
I_DOC_FORMAT = "File extension
* I_TITLE = "Explanatory text
* I_SHOW_TOOLBARS = 'X' "Display Toolbars in Editor
* I_TRANSPORT = ' ' "Activate transport connection
* I_CORR_NUMBER = "Request/Task

EXCEPTIONS
CANCELLED = 1 ERROR = 2 NAMESPACE_ERROR = 3
.



IMPORTING Parameters details for SOLAR_TEMPLATE_CREATE

I_TYPE - Content Type

Data type: TNOTEP-NOTETYPE
Optional: No
Call by Reference: Yes

I_DOC_FORMAT - File extension

Data type: PROJ_FILE
Optional: No
Call by Reference: Yes

I_TITLE - Explanatory text

Data type: TNOTETPR-TEXT
Optional: Yes
Call by Reference: Yes

I_SHOW_TOOLBARS - Display Toolbars in Editor

Data type: CHAR1
Default: 'X'
Optional: Yes
Call by Reference: Yes

I_TRANSPORT - Activate transport connection

Data type: CHAR1
Default: SPACE
Optional: Yes
Call by Reference: Yes

I_CORR_NUMBER - Request/Task

Data type: E070-TRKORR
Optional: Yes
Call by Reference: Yes

EXCEPTIONS details

CANCELLED - User Termination

Data type:
Optional: No
Call by Reference: Yes

ERROR - General Error

Data type:
Optional: No
Call by Reference: Yes

NAMESPACE_ERROR - Incorrect namespace

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for SOLAR_TEMPLATE_CREATE 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_i_type  TYPE TNOTEP-NOTETYPE, "   
lv_cancelled  TYPE TNOTEP, "   
lv_error  TYPE TNOTEP, "   
lv_i_doc_format  TYPE PROJ_FILE, "   
lv_i_title  TYPE TNOTETPR-TEXT, "   
lv_namespace_error  TYPE TNOTETPR, "   
lv_i_show_toolbars  TYPE CHAR1, "   'X'
lv_i_transport  TYPE CHAR1, "   SPACE
lv_i_corr_number  TYPE E070-TRKORR. "   

  CALL FUNCTION 'SOLAR_TEMPLATE_CREATE'  "
    EXPORTING
         I_TYPE = lv_i_type
         I_DOC_FORMAT = lv_i_doc_format
         I_TITLE = lv_i_title
         I_SHOW_TOOLBARS = lv_i_show_toolbars
         I_TRANSPORT = lv_i_transport
         I_CORR_NUMBER = lv_i_corr_number
    EXCEPTIONS
        CANCELLED = 1
        ERROR = 2
        NAMESPACE_ERROR = 3
. " SOLAR_TEMPLATE_CREATE




ABAP code using 7.40 inline data declarations to call FM SOLAR_TEMPLATE_CREATE

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 NOTETYPE FROM TNOTEP INTO @DATA(ld_i_type).
 
 
 
 
"SELECT single TEXT FROM TNOTETPR INTO @DATA(ld_i_title).
 
 
DATA(ld_i_show_toolbars) = 'X'.
 
DATA(ld_i_transport) = ' '.
 
"SELECT single TRKORR FROM E070 INTO @DATA(ld_i_corr_number).
 


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!