2007 Jun 19 11:18 AM
Hi all,
Can anyone post the code for the program RSCMSLST if it is available in the 4.6c
version of your system?
Thanks in advance,
keerthi.
Hi all,
Can anyone post the code for the program RSCMSLST if it is available in the 4.6c
version of your system?
Thanks in advance,
keerthi.
2007 Jun 19 11:21 AM
Hi,
&----
*& Report RSCMSLST
*&
&----
*& Creates a list of document ids for a repository on a SAP Content
*& Server. The list is stored in the file system of the application
*& server or the frontend PC.
&----
REPORT RSCMSLST.
*----
Selection screen
*----
SELECTION-SCREEN BEGIN OF BLOCK DOCLIST
WITH FRAME TITLE TEXT-DLT.
PARAMETERS:
LSTFILE TYPE TRFILE OBLIGATORY,
USE_FE TYPE C AS CHECKBOX,
LOGFIL TYPE C AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK DOCLIST.
SELECTION-SCREEN BEGIN OF BLOCK SOURCE
WITH FRAME TITLE TEXT-SCT.
PARAMETERS:
CAT TYPE SDOKSTCAE-STOR_CAT VALUE CHECK,
REP TYPE CREP_HTTP-CREP_ID VALUE CHECK.
SELECTION-SCREEN END OF BLOCK SOURCE.
*----
Data
*----
TYPES: BEGIN OF T_DOCLIST,
LINE(40) TYPE C,
END OF T_DOCLIST.
DATA: DOCLIST TYPE STANDARD TABLE OF T_DOCLIST,
LOG_FILNM TYPE FILENAME-FILEINTERN,
FILE_NAME TYPE TRFILE.
CONSTANTS: TIMEOUT TYPE I VALUE 86400. "One day in seconds
*----
Procedure
*----
... Resolve logical file name (if requested) ...
IF LOGFIL IS INITIAL.
FILE_NAME = LSTFILE.
ELSE.
LOG_FILNM = LSTFILE.
TRANSLATE LOG_FILNM TO UPPER CASE. "#EC SYNTCHAR
CALL FUNCTION 'FILE_GET_NAME'
EXPORTING
LOGICAL_FILENAME = LOG_FILNM
USE_PRESENTATION_SERVER = USE_FE
ELEMINATE_BLANKS = SPACE "Allow blanks in file name
IMPORTING
FILE_NAME = FILE_NAME
EXCEPTIONS
FILE_NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
ENDIF.
... Get list of document ids from content server ...
CALL FUNCTION 'SCMS_DOC_IDLIST'
EXPORTING
STOR_CAT = CAT
CREP_ID = REP
TIMEOUT = TIMEOUT
TABLES
DOCLIST = DOCLIST
EXCEPTIONS
ERROR_CONFIG = 1
BAD_STORAGE_TYPE = 2
OTHERS = 3.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
CALL FUNCTION 'SCMS_DOWNLOAD'
EXPORTING
FILENAME = FILE_NAME
BINARY = ' '
FRONTEND = USE_FE
TABLES
DATA = DOCLIST
EXCEPTIONS
ERROR = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
PERFORM WRITE_MESSAGE USING '00' 'S' '001' TEXT-SUC SPACE SPACE SPACE.
*eject
&----
*& Form write_message
&----
Displays a message
----
-->P_MSGID Message Id
-->P_MSGTY Message type
-->P_MSGNO Message number
-->P_MSGV1 Message variable 1
-->P_MSGV2 Message variable 2
-->P_MSGV3 Message variable 3
-->P_MSGV4 Message variable 4
----
FORM WRITE_MESSAGE
USING P_MSGID LIKE SY-MSGID
P_MSGTY LIKE SY-MSGTY
P_MSGNO LIKE SY-MSGNO
P_MSGV1 LIKE SY-MSGV1
P_MSGV2 LIKE SY-MSGV2
P_MSGV3 LIKE SY-MSGV3
P_MSGV4 LIKE SY-MSGV4.
DATA: MSGSTRING TYPE STRING.
IF SY-BATCH IS INITIAL AND P_MSGTY NE 'S'.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4
INTO MSGSTRING.
WRITE: / MSGSTRING.
ELSE.
MESSAGE ID P_MSGID TYPE P_MSGTY NUMBER P_MSGNO
WITH P_MSGV1 P_MSGV2 P_MSGV3 P_MSGV4.
ENDIF.
ENDFORM. "write_message
Thanks.
2007 Jun 19 11:22 AM
Please reward,
Rakesh.
&----
*& Report RSCMSLST
*&
&----
*& Creates a list of document ids for a repository on a SAP Content
*& Server. The list is stored in the file system of the application
*& server or the frontend PC.
&----
REPORT RSCMSLST.
*----
Selection screen
*----
SELECTION-SCREEN BEGIN OF BLOCK doclist
WITH FRAME TITLE text-dlt.
PARAMETERS:
lstfile TYPE trfile OBLIGATORY,
use_fe TYPE c AS CHECKBOX,
logfil TYPE c AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK doclist.
SELECTION-SCREEN BEGIN OF BLOCK source
WITH FRAME TITLE text-sct.
PARAMETERS:
cat TYPE sdokstcae-stor_cat VALUE CHECK,
rep TYPE crep_http-crep_id VALUE CHECK.
SELECTION-SCREEN END OF BLOCK source.
*----
Data
*----
TYPES: BEGIN OF t_doclist,
line(40) TYPE c,
END OF t_doclist.
DATA: doclist TYPE STANDARD TABLE OF t_doclist,
log_filnm TYPE filename-fileintern,
file_name TYPE trfile.
constants: timeout type i value 86400. "One day in seconds
*----
Procedure
*----
... Resolve logical file name (if requested) ...
IF logfil IS INITIAL.
file_name = lstfile.
ELSE.
log_filnm = lstfile.
TRANSLATE log_filnm TO UPPER CASE. "#EC SYNTCHAR
CALL FUNCTION 'FILE_GET_NAME'
EXPORTING
logical_filename = log_filnm
use_presentation_server = use_fe
eleminate_blanks = space "Allow blanks in file name
IMPORTING
file_name = file_name
EXCEPTIONS
file_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
ENDIF.
... Get list of document ids from content server ...
CALL FUNCTION 'SCMS_DOC_IDLIST'
EXPORTING
stor_cat = cat
crep_id = rep
timeout = timeout
TABLES
doclist = doclist
EXCEPTIONS
error_config = 1
bad_storage_type = 2
OTHERS = 3.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
CALL FUNCTION 'SCMS_DOWNLOAD'
EXPORTING
filename = file_name
binary = ' '
frontend = use_fe
TABLES
data = doclist
EXCEPTIONS
error = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
PERFORM write_message USING '00' 'S' '001' text-suc space space space.
*eject
&----
*& Form write_message
&----
Displays a message
----
-->P_MSGID Message Id
-->P_MSGTY Message type
-->P_MSGNO Message number
-->P_MSGV1 Message variable 1
-->P_MSGV2 Message variable 2
-->P_MSGV3 Message variable 3
-->P_MSGV4 Message variable 4
----
FORM write_message
USING p_msgid LIKE sy-msgid
p_msgty LIKE sy-msgty
p_msgno LIKE sy-msgno
p_msgv1 LIKE sy-msgv1
p_msgv2 LIKE sy-msgv2
p_msgv3 LIKE sy-msgv3
p_msgv4 LIKE sy-msgv4.
DATA: msgstring TYPE string.
IF sy-batch IS INITIAL AND p_msgty NE 'S'.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
INTO msgstring.
WRITE: / msgstring.
ELSE.
MESSAGE ID p_msgid TYPE p_msgty NUMBER p_msgno
WITH p_msgv1 p_msgv2 p_msgv3 p_msgv4.
ENDIF.
ENDFORM. "write_message
2007 Jun 19 11:23 AM
Hi Keerti,
&----
*& Report RSCMSLST
*&
&----
*& Creates a list of document ids for a repository on a SAP Content
*& Server. The list is stored in the file system of the application
*& server or the frontend PC.
&----
REPORT RSCMSLST.
*----
Selection screen
*----
SELECTION-SCREEN BEGIN OF BLOCK doclist
WITH FRAME TITLE text-dlt.
PARAMETERS:
lstfile TYPE trfile OBLIGATORY,
use_fe TYPE c AS CHECKBOX,
logfil TYPE c AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK doclist.
SELECTION-SCREEN BEGIN OF BLOCK source
WITH FRAME TITLE text-sct.
PARAMETERS:
cat TYPE sdokstcae-stor_cat VALUE CHECK,
rep TYPE crep_http-crep_id VALUE CHECK.
SELECTION-SCREEN END OF BLOCK source.
*----
Data
*----
TYPES: BEGIN OF t_doclist,
line(40) TYPE c,
END OF t_doclist.
DATA: doclist TYPE STANDARD TABLE OF t_doclist,
log_filnm TYPE filename-fileintern,
file_name TYPE trfile.
constants: timeout type i value 86400. "One day in seconds
*----
Procedure
*----
... Resolve logical file name (if requested) ...
IF logfil IS INITIAL.
file_name = lstfile.
ELSE.
log_filnm = lstfile.
TRANSLATE log_filnm TO UPPER CASE. "#EC SYNTCHAR
CALL FUNCTION 'FILE_GET_NAME'
EXPORTING
logical_filename = log_filnm
use_presentation_server = use_fe
eleminate_blanks = space "Allow blanks in file name
IMPORTING
file_name = file_name
EXCEPTIONS
file_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
ENDIF.
... Get list of document ids from content server ...
CALL FUNCTION 'SCMS_DOC_IDLIST'
EXPORTING
stor_cat = cat
crep_id = rep
timeout = timeout
TABLES
doclist = doclist
EXCEPTIONS
error_config = 1
bad_storage_type = 2
OTHERS = 3.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
CALL FUNCTION 'SCMS_DOWNLOAD'
EXPORTING
filename = file_name
binary = ' '
frontend = use_fe
TABLES
data = doclist
EXCEPTIONS
error = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
PERFORM write_message USING '00' 'S' '001' text-suc space space space.
*eject
&----
*& Form write_message
&----
Displays a message
----
-->P_MSGID Message Id
-->P_MSGTY Message type
-->P_MSGNO Message number
-->P_MSGV1 Message variable 1
-->P_MSGV2 Message variable 2
-->P_MSGV3 Message variable 3
-->P_MSGV4 Message variable 4
----
FORM write_message
USING p_msgid LIKE sy-msgid
p_msgty LIKE sy-msgty
p_msgno LIKE sy-msgno
p_msgv1 LIKE sy-msgv1
p_msgv2 LIKE sy-msgv2
p_msgv3 LIKE sy-msgv3
p_msgv4 LIKE sy-msgv4.
DATA: msgstring TYPE string.
IF sy-batch IS INITIAL AND p_msgty NE 'S'.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
INTO msgstring.
WRITE: / msgstring.
ELSE.
MESSAGE ID p_msgid TYPE p_msgty NUMBER p_msgno
WITH p_msgv1 p_msgv2 p_msgv3 p_msgv4.
ENDIF.
ENDFORM. "write_message
Regards...
BALAJI ( Assign points if this helps u....)
2007 Jun 19 11:29 AM
Hi,
Is this from 4.6 c version, because the structure sdokstcae is not present in my system?
Regards,
keerthi.
Message was edited by:
keerthi kiran varanasi
2007 Jun 19 11:32 AM
*&---------------------------------------------------------------------*
*& Report RSCMSLST
*&
*&---------------------------------------------------------------------*
*& Creates a list of document ids for a repository on a SAP Content
*& Server. The list is stored in the file system of the application
*& server or the frontend PC.
*&---------------------------------------------------------------------*
REPORT rscmslst.
*---------------------------------------------------------------------
* Selection screen
*---------------------------------------------------------------------
SELECTION-SCREEN BEGIN OF BLOCK doclist
WITH FRAME TITLE text-dlt.
PARAMETERS:
lstfile TYPE trfile OBLIGATORY,
use_fe TYPE c AS CHECKBOX,
logfil TYPE c AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK doclist.
SELECTION-SCREEN BEGIN OF BLOCK source
WITH FRAME TITLE text-sct.
PARAMETERS:
cat TYPE sdokstcae-stor_cat VALUE CHECK,
rep TYPE crep_http-crep_id VALUE CHECK.
SELECTION-SCREEN END OF BLOCK source.
*---------------------------------------------------------------------
* Data
*---------------------------------------------------------------------
TYPES: BEGIN OF t_doclist,
line(40) TYPE c,
END OF t_doclist.
DATA: doclist TYPE STANDARD TABLE OF t_doclist,
log_filnm TYPE filename-fileintern,
file_name TYPE trfile.
constants: timeout type i value 86400. "One day in seconds
*---------------------------------------------------------------------
* Procedure
*---------------------------------------------------------------------
* ... Resolve logical file name (if requested) ...
IF logfil IS INITIAL.
file_name = lstfile.
ELSE.
log_filnm = lstfile.
TRANSLATE log_filnm TO UPPER CASE. "#EC SYNTCHAR
CALL FUNCTION 'FILE_GET_NAME'
EXPORTING
logical_filename = log_filnm
use_presentation_server = use_fe
eleminate_blanks = space "Allow blanks in file name
IMPORTING
file_name = file_name
EXCEPTIONS
file_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
ENDIF.
* ... Get list of document ids from content server ...
CALL FUNCTION 'SCMS_DOC_IDLIST'
EXPORTING
stor_cat = cat
crep_id = rep
timeout = timeout
TABLES
doclist = doclist
EXCEPTIONS
error_config = 1
bad_storage_type = 2
OTHERS = 3.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
* ... Store document list in the file system
CALL FUNCTION 'SCMS_DOWNLOAD'
EXPORTING
filename = file_name
binary = ' '
frontend = use_fe
TABLES
data = doclist
EXCEPTIONS
error = 1
OTHERS = 2.
IF sy-subrc <> 0.
IF sy-msgty IS NOT INITIAL.
PERFORM write_message
USING sy-msgid sy-msgty sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
* ... Store document list in the file system
PERFORM write_message USING '00' 'S' '001' text-suc space space space.
*eject
*&--------------------------------------------------------------------*
*& Form write_message
*&--------------------------------------------------------------------*
* Displays a message
*---------------------------------------------------------------------*
* -->P_MSGID Message Id
* -->P_MSGTY Message type
* -->P_MSGNO Message number
* -->P_MSGV1 Message variable 1
* -->P_MSGV2 Message variable 2
* -->P_MSGV3 Message variable 3
* -->P_MSGV4 Message variable 4
*---------------------------------------------------------------------*
FORM write_message
USING p_msgid LIKE sy-msgid
p_msgty LIKE sy-msgty
p_msgno LIKE sy-msgno
p_msgv1 LIKE sy-msgv1
p_msgv2 LIKE sy-msgv2
p_msgv3 LIKE sy-msgv3
p_msgv4 LIKE sy-msgv4.
DATA: msgstring TYPE string.
IF sy-batch IS INITIAL AND p_msgty NE 'S'.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
INTO msgstring.
WRITE: / msgstring.
ELSE.
MESSAGE ID p_msgid TYPE p_msgty NUMBER p_msgno
WITH p_msgv1 p_msgv2 p_msgv3 p_msgv4.
ENDIF.
ENDFORM. "write_messagereward points if it is usefull ...
Girish
2007 Jun 19 11:49 AM
Hi,
could you confirm if this is from 4.6c version,so that i can proceed creating the table.
Regards,
keerthi
2007 Jun 19 12:38 PM
Hi,
In 4.6 the program is not there. But in 4.7, The program and structure is also there.
Code :
&----
*& Report RSCMSLST
*&
&----
*& Creates a list of document ids for a repository on a SAP Content
*& Server. The list is stored in the file system of the application
*& server or the frontend PC.
&----
REPORT RSCMSLST.
*----
Selection screen
*----
SELECTION-SCREEN BEGIN OF BLOCK DOCLIST
WITH FRAME TITLE TEXT-DLT.
PARAMETERS:
LSTFILE TYPE TRFILE OBLIGATORY,
USE_FE TYPE C AS CHECKBOX,
LOGFIL TYPE C AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK DOCLIST.
SELECTION-SCREEN BEGIN OF BLOCK SOURCE
WITH FRAME TITLE TEXT-SCT.
PARAMETERS:
CAT TYPE SDOKSTCAE-STOR_CAT VALUE CHECK,
REP TYPE CREP_HTTP-CREP_ID VALUE CHECK.
SELECTION-SCREEN END OF BLOCK SOURCE.
*----
Data
*----
TYPES: BEGIN OF T_DOCLIST,
LINE(40) TYPE C,
END OF T_DOCLIST.
DATA: DOCLIST TYPE STANDARD TABLE OF T_DOCLIST,
LOG_FILNM TYPE FILENAME-FILEINTERN,
FILE_NAME TYPE TRFILE.
CONSTANTS: TIMEOUT TYPE I VALUE 86400. "One day in seconds
*----
Procedure
*----
... Resolve logical file name (if requested) ...
IF LOGFIL IS INITIAL.
FILE_NAME = LSTFILE.
ELSE.
LOG_FILNM = LSTFILE.
TRANSLATE LOG_FILNM TO UPPER CASE. "#EC SYNTCHAR
CALL FUNCTION 'FILE_GET_NAME'
EXPORTING
LOGICAL_FILENAME = LOG_FILNM
USE_PRESENTATION_SERVER = USE_FE
ELEMINATE_BLANKS = SPACE "Allow blanks in file name
IMPORTING
FILE_NAME = FILE_NAME
EXCEPTIONS
FILE_NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
ENDIF.
... Get list of document ids from content server ...
CALL FUNCTION 'SCMS_DOC_IDLIST'
EXPORTING
STOR_CAT = CAT
CREP_ID = REP
TIMEOUT = TIMEOUT
TABLES
DOCLIST = DOCLIST
EXCEPTIONS
ERROR_CONFIG = 1
BAD_STORAGE_TYPE = 2
OTHERS = 3.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
CALL FUNCTION 'SCMS_DOWNLOAD'
EXPORTING
FILENAME = FILE_NAME
BINARY = ' '
FRONTEND = USE_FE
TABLES
DATA = DOCLIST
EXCEPTIONS
ERROR = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
IF SY-MSGTY IS NOT INITIAL.
PERFORM WRITE_MESSAGE
USING SY-MSGID SY-MSGTY SY-MSGNO
SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
RETURN. "<--- Leave this program
ENDIF.
... Store document list in the file system
PERFORM WRITE_MESSAGE USING '00' 'S' '001' TEXT-SUC SPACE SPACE SPACE.
*eject
&----
*& Form write_message
&----
Displays a message
----
-->P_MSGID Message Id
-->P_MSGTY Message type
-->P_MSGNO Message number
-->P_MSGV1 Message variable 1
-->P_MSGV2 Message variable 2
-->P_MSGV3 Message variable 3
-->P_MSGV4 Message variable 4
----
FORM WRITE_MESSAGE
USING P_MSGID LIKE SY-MSGID
P_MSGTY LIKE SY-MSGTY
P_MSGNO LIKE SY-MSGNO
P_MSGV1 LIKE SY-MSGV1
P_MSGV2 LIKE SY-MSGV2
P_MSGV3 LIKE SY-MSGV3
P_MSGV4 LIKE SY-MSGV4.
DATA: MSGSTRING TYPE STRING.
IF SY-BATCH IS INITIAL AND P_MSGTY NE 'S'.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4
INTO MSGSTRING.
WRITE: / MSGSTRING.
ELSE.
MESSAGE ID P_MSGID TYPE P_MSGTY NUMBER P_MSGNO
WITH P_MSGV1 P_MSGV2 P_MSGV3 P_MSGV4.
ENDIF.
ENDFORM. "write_message
Thanks.
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |