cancel
Showing results for 
Search instead for 
Did you mean: 

Determination of Content Repository for E-Mail attachments

Former Member
0 Kudos

Hi Friends,

We have a requirement where in the email attachments sent to

testsingapore@customercarecom --> to be stored in content repository C1

testbrazil@customercarecom --> to be stored in content repository C2

We need to determine the content repository dynamically. we tried analysing to find any parameters available for ERMS in rule policies. couldnt find any helpful info. Can some one share us your view points on this..

Thanks,

Eureka

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

We have tried using the function module get_print_parameters with the following parameters and getting the error saying " ARCH Do not exist". Any pointers on this would be of great help.

The below entries are maintained in OAC3 transaction.

wa_TOA_DARA-SAP_OBJECT = 'ERMSSUPRT2'.

wa_TOA_DARA-AR_OBJECT = 'MSWORD'.


  *      C_ARCHIVE_INDEX = TOA_DARA.
CALL FUNCTION 'GET_PRINT_PARAMETERS'
       EXPORTING
             ARCHIVE_ID           = 'RQ'
            ARCHIVE_INFO         = '000'
            ARCHIVE_MODE         =  '2'
            ARCHIVE_TEXT         = 'Korrespondenz'
            AR_OBJECT            = wa_TOA_DARA-AR_OBJECT
            IMMEDIATELY          = '3'  
            NO_DIALOG              = 'X'
            RECEIVER             = SY-UNAME
            SAP_OBJECT           = wa_TOA_DARA-SAP_OBJECT
           IMPORTING
           OUT_ARCHIVE_PARAMETERS = lv_arcparms
           OUT_PARAMETERS         = lv_priparms
           VALID                  = lv_valid
       EXCEPTIONS
            ARCHIVE_INFO_NOT_FOUND = 1
            INVALID_PRINT_PARAMS   = 2
            INVALID_ARCHIVE_PARAMS = 3
            OTHERS                 = 4. 

Former Member
0 Kudos

Hello,

As you can see in OAC3 the content repository is determined by a combination of ObjectType and Doc. Type. You'll need to create a new document type to send the document to a different repository. One solution is to have the print program do the substitution for the document type (AR_OBJECT) according to your required logic prior to the OPEN_FORM for parameters ARCHIVE_INDEX and ARCHIVE_PARAMS.

i.e.


IF cond1.
  TOA_DARA-AR_OBJECT = 'ERMSSUPRT1'.
  ARC_PARAMS-AR_OBJECT = 'ERMSSUPRT1'.
ELSE.
  TOA_DARA-AR_OBJECT = 'ERMSSUPRT2'.
  ARC_PARAMS-AR_OBJECT = 'ERMSSUPRT2'.
ENDIF.

CALL FUNCTION 'OPEN_FORM'
...

Regards,

Michael

Former Member
0 Kudos

Thanks Michael for your suggestion. Do you have any sample programs or references on this..Like what logic needs to be written in open_form. Presently i have shared the code that we are working on.. any pointers on this would be of great help.

Thanks,

Eureka

Answers (0)