Ansicht
Dokumentation

SO_DLI_INSERT_API1 - SAPoffice: Insert distribution list using RFC

SO_DLI_INSERT_API1 - SAPoffice: Insert distribution list using RFC

PERFORM Short Reference   RFUMSV00 - Advance Return for Tax on Sales/Purchases  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

This function module is used to create a new distribution list.

Import parameters

FOLDER_ID
Object ID of the folder in which the distribution list is to be created.
DLI_INSERT_DATA
This structure must contain the attributes of the distribution list to be created.
  • OBJ_NAME
Name of the distribution list. The name must be unique for the shared folders or the private area of each user.
  • OBJ_DESCR
Title (short description) of the distribution list.
  • OBJ_LANGU
Language of the distribution list.
  • OBJ_SORT
Sort field of the distribution list. This term can be searched for in the attribute search.
  • OBJ_EXPDAT.
This field is not used.
  • SENSITIVTY
Sensitivity of the distribution list.
A private distribution list can have the following sensitivity:
  • 'O' : standard, normal sensitivity

  • 'F' : functional, entry possible but no difference to standard

  • 'P' : confidential, not visible to the substitute

Only the sensitivity 'O' is allowed for shared distribution lists.
  • OBJ_PRIO
This field is not used.
  • NO_CHANGE
This field is not used.
  • PRIORITY
This field is not used.
  • EXPIRY_DAT
This field is not used.
  • SUBSCRIPT
If this flag is set ('X'), the distribution list is a subscription list. Since only shared distribution lists can be subscription lists, the flag SHARED_DLI must therefore also be set.
  • SHARED_DLI
If this flag is set ('X'), the distribution list is a shared distribution list.

Export parameters

DLI_INFO
This structure contains the attributes of the newly created distribution list.
  • OBJECT_ID
Object ID of the distribution list.
  • OBJ_TYPE
Type of document ('DLI').
  • OBJ_NAME
Name of distribution list.
  • OBJ_DESCR
Title (short description) of distribution list.
  • OBJ_LANGU
Language of distribution list.
  • OBJ_SORT
Sort field of the distribution list. This term can be searched for in the attribute search.
  • CREATOR_ID
SAPoffice ID of the creator of the distribution list.
  • CREAT_NAME
SAPoffice name of the creator of the distribution list. The SAPoffice name is unique client-wide.
  • CREAT_FNAM
Full name of the creator of the distribution list from the address management.
  • CREAT_DATE
Date distribution list was created.
  • CREAT_TIME
Time distribution list was created.
  • CHANGER_ID
SAPoffice ID of person who last changed the distribution list.
  • CHANG_NAME
SAPoffice name of person who last changed the distribution list. The SAPoffice name is unique client-wide.
  • CHANG_FNAM
Full name of person who last changed the distribution list from the address management.
  • CHANG_DATE
Date of last change.
  • CHANG_TIME
Time of last change.
  • OWNER_ID
SAPoffice ID of the owner of the distribution list.
  • OWNER_NAM
SAPoffice name of the owner of the distribution list. The SAPoffice name is unique client-wide.
  • OWNER_FNAM
Full name of the owner of the distribution list from the address management.
  • LAST_ACCES
Date distribution list was created/changed. Contains the latest of the two values.
  • OBJ_EXPDAT
This field is not used.
  • SENSITIVTY
Sensitivity of the distribution list.
A private distribution list can have the following sensitivity:
  • 'O' : standard, normal sensitivity

  • 'F' : functional, entry possible but no difference to standard

  • 'P' : confidential, not visible to substitute

Only sensitivity 'O' is allowed for shared distribution lists.
  • OBJ_PRIO
This field is not used.
  • NO_CHANGE
This field is not used.
  • PROC_TYPE
This field is not used.
  • PROC_NAME
This field is not used.
  • PROC_SYST
This field is not used.
  • PROC_CLIENT
This field is not used.
  • SKIP_SCREEN
This field is not used.
  • TO_DO_OUT
This field is not used.
  • FREE_DEL
This field is not used.
  • SUBSCRIPT
If this flag is set ('X'), the distribution list is a subscription list. Since only shared distribution lists can be subscription lists, the flag SHARED_DLI is therefore also set.
  • SIZE
Contains the number of entries in the distribution list.
  • SHARED_DLI
If this flag is set ('X'), the distribution list is a shared distribution list.
  • PRIORITY
This field is not used.
  • EXPIRY_DAT
This field is not used.

Table parameters

DLI_ENTRIES
This table must contain the entries of the distribution list to be created.
  • MEMBER_NAM
Unique name of the entry. Depending on the entry type, it may be the SAPoffice name of a user, the name of a private or shared distribution list, or the name of the ID of an external address.
  • MEMBER_ID
ID of the entry.
  • MEMBER_TYP
Type of entry.
  • ' ' : Internal user

  • 'P' : Private distribution list

  • 'C' : Shared distribution list

  • 'A' : External address

  • 'U' : Internet address

  • 'X' : X.400 address

  • 'F' : Fax number

  • 'R' : Remote SAP name

  • FULL_NAME
Descriptive name of the entry. If the entry is an internal user, the relevant name from the address management is used here. In the case of external addresses, an exact description of the address is inserted.
  • MEMBER_ADR
If the entry is an external address, it is specified fully in this field.
The following address types are possible:
  • a fax number in the form of the structure SADRFD

  • an Internet address in the form of the structure SADRUD

  • an SAP remote address in the form of the structure SADR7D

  • an X.400 address in the form of the structure SADR8D

The meaning of the value entered here can be derived from the field MEMBER_TYP.

Exceptions

DLI_ALREADY_EXIST
The name of the distribution list to be created already exists. If you tried to create a private distribution list, there is already a distribution list with the same name in the outbox, a private folder, or in the private trash. If you tried to create a shared distribution list, there is already one with this name in a shared folder or the shared trash.
FOLDER_NOT_EXIST
The folder in which the distribution list is to be created does not exist. An incorrect ID may have been passed or the relevant folder has been deleted.
OPERATION_NO_AUTHORIZATION
It was not possible to create the distribution list. This may be because it was to be created in the private area of another user or in a shared folder for which the active user does not have a create authorization for distribution lists.
PARAMETER_ERROR
An invalid combination of parameter values was passed to the function module.
X_ERROR
An internal error or a database inconsistency occurred.
ENQUEUE_ERROR
The folder in which the distribution is to be created could not be locked. It may be being processed by another user.

Example

Creating an empty subscription list in the shared folders.

DATA: TAB_ENTRIES LIKE SODLIENTI1 OCCURS 0 WITH HEADER LINE.
DATA: DLI_CHNG LIKE SODLICHGI1.
DATA: USER_DATA LIKE SOUDATAI1.
CALL FUNCTION 'SO_USER_READ_API1'
IMPORTING
USER_DATA = USER_DATA
EXCEPTIONS
OTHERS = 1.
IF SY-SUBRC <> 0.
WRITE: / 'User data could not be read !'.
EXIT.
ENDIF.
DLI_CHNG-OBJ_NAME = 'RUMOURS'.
DLI_CHNG-OBJ_DESCR = 'Gossip for everyone'.
DLI_CHNG-OBJ_LANGU = SY-LANGU.
DLI_CHNG-SENSITIVTY = 'O'.
DLI_CHNG-SUBSCRIPT = 'X'.
DLI_CHNG-SHARED_DLI = 'X'.
CALL FUNCTION 'SO_DLI_INSERT_API1'
EXPORTING
FOLDER_ID = USER_DATA-SHAREDFOL
DLI_INSERT_DATA = DLI_CHNG
TABLES
TAB_ENTRIES
EXCEPTIONS
DLI_ALREADY_EXIST = 1
OPERATION_NO_AUTHORIZATION = 3
ENQUEUE_ERROR = 6
OTHERS = 99.
CASE SY-SUBRC.
WHEN 0.
WRITE: / 'Distribution list was created !'.
WHEN 1.
WRITE: / 'Distribution list with this name already exists !'.
WHEN 3.
WRITE: / 'No authorization to create a distribution list !'.
WHEN 6.
WRITE: / 'Relevant folder is currently being processed !'.
WHEN OTHERS.
WRITE: / 'Unknown error occurred !'.
ENDCASE.

Notes

The function modules SO_FOLDER_INSERT_API1 or SO_DOCUMENT_INSERT_API1 must be used to create folders or documents.

Further information

Information on calling the function module SO_USER_READ_API1 can be found in the documentation of the function module.





Parameters

DLI_ENTRIES
DLI_INFO
DLI_INSERT_DATA
FOLDER_ID

Exceptions

DLI_ALREADY_EXIST
ENQUEUE_ERROR
FOLDER_NOT_EXIST
OPERATION_NO_AUTHORIZATION
PARAMETER_ERROR
X_ERROR

Function Group

SOI1

Fill RESBD Structure from EBP Component Structure   PERFORM Short Reference  
This documentation is copyright by SAP AG.

Length: 14002 Date: 20240523 Time: 092344     sap01-206 ( 110 ms )