Ansicht
Dokumentation

09533 - User Messages

09533 - User Messages

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

User Messages

Here is an *untested* ABAP program that I got from somebody. I have never
compiled or tested it, only created the ABAP program in DEV.

*=============================================================
* This program will send a system message to a specific user
* and also has the ability to lock the user id also. User
* must have the SAP_ALL profile to be able to use program.
*
* Created By: 02-NOV-2001
*=============================================================
* Modification History:
*=============================================================
*
*=============================================================

REPORT Z_SNDLCK_MSG .


TABLES: USR02.
DATA: I_USR02 LIKE USR02 OCCURS 0 WITH HEADER LINE.

PARAMETERS: MESSAGE(128) TYPE C OBLIGATORY LOWER CASE.
SELECTION-SCREEN: SKIP.
PARAMETERS: INFORM RADIOBUTTON GROUP RADI.
PARAMETERS: LOGOFF RADIOBUTTON GROUP RADI.
SELECTION-SCREEN: SKIP.
SELECT-OPTIONS: USERNAME FOR USR02-BNAME OBLIGATORY.

AUTHORITY-CHECK OBJECT 'S_ADMI_FCD'
ID 'S_ADMI_FCD' FIELD 'PADM'.

IF SY-SUBRC NE 0.
MESSAGE E000(38) WITH 'You are not authorized for process admin'.
ENDIF.

SELECT * FROM USR02 INTO TABLE I_USR02
WHERE USTYP = 'A'
AND BNAME IN USERNAME.

WRITE: / SY-SYSID NO-GAP, SY-MANDT.
WRITE: / SY-DATUM MM/DD/YYYY, SY-UZEIT.
SKIP.
IF INFORM = 'X'.
WRITE: / 'Message:', MESSAGE.
SKIP.
WRITE: / 'Contacted Users:'.
SKIP.
ELSE.
WRITE: / 'Automatic Logoff Users:'.
SKIP.
ENDIF.
LOOP AT I_USR02.
IF INFORM = 'X'.
PERFORM INFORM_USER.
ELSE.
PERFORM SHOW_USER_TO_THE_DOOR.
ENDIF.
ENDLOOP.

FORM SHOW_USER_TO_THE_DOOR.
CALL FUNCTION 'TH_POPUP'
EXPORTING
CLIENT = SY-MANDT
USER = I_USR02-BNAME
MESSAGE = 'Automatic Logoff Initiated'
CUT_BLANKS = 'X'
EXCEPTIONS
USER_NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC = 0.
WRITE: /15 I_USR02-BNAME.
CALL FUNCTION 'TH_DELETE_USER'
EXPORTING
USER = I_USR02-BNAME
CLIENT = SY-MANDT
EXCEPTIONS
AUTHORITY_ERROR = 1
OTHERS = 2.
ENDIF.
ENDFORM.

FORM INFORM_USER.
CALL FUNCTION 'TH_POPUP'
EXPORTING
CLIENT = SY-MANDT
USER = I_USR02-BNAME
MESSAGE = MESSAGE
CUT_BLANKS = 'X'
EXCEPTIONS
USER_NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC = 0.
WRITE: /15 I_USR02-BNAME.
ENDIF.

Good luck,
Chris

-----Original Message-----
From: geraldjh2003 <geraldjhZaol.com> [mailto:geraldjhZaol.com]
Sent: Tuesday, March 04, 2003 3:19 PM
To: DoNotReply@consolut.eu
Subject: User Messages


Transaction SM02 is a way to send system messages but is there a way
to send a user message in the same fashion? The SAP Library lists the
following in the index but doesn't give a transaction.

Graphical User Interface (BC-FES-GUI)
Short message to other R/3 System users.

You can send a user message to any number of users. It is displayed
in a window that is displayed once.




Have a look to our homepage at: http://www.consolut.net
DoNotReply@consolut.eu

Your use of consolut is subject to http://www.consolut.net


Durban Tours - Südafrika Safari

ROGBILLS - Synchronize billing plans   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.

Length: 4226 Date: 20240419 Time: 212325     sap01-206 ( 3 ms )