Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

USER_EXIT - define actions, when user logs on....

Former Member
0 Likes
996

Hello,

is there a function module or sth. like this, which is executed, when a user logs on?

For example...If a user logs on, a message should appear on his screen, but only on his one.

Can I define anywhere what happens, if a user logs on?

thx, holger

6 REPLIES 6
Read only

Former Member
0 Likes
939

Are you looking for a message to go out to all users? If yes, this is done with transaction SM02.

If you are looking for a user exit to customize specific user messages for certain users, check out enhancement SUSR0001. It uses function module EXIT_SAPLSUSF_001. It should be used with a project in transaction CMOD so it can be activated/deactivated as needed.

Norm

Read only

Former Member
0 Likes
939

Hi Holger,

1. SUSR0001

This is the enhancment / user-exit.

regards,

amit m.

Read only

0 Likes
939

thx,

but where can I define for users individually what should happen when they log on.

For example:

If a user logs on, a screen should appear which asks to change the password.

How can this be achieved?

thx,

holger

Read only

0 Likes
939

hi again,

1. After using CMOD( for craeting the project

and including the enchnacement)

2. There is the FM.

EXIT_SAPLSUSF_001.

3. In this double click on the include

to create it.

4. then u have to write ABAP code

using

if sy-uname = 'XYZ'.

                • logic

endif.

regards,

amit m.

Read only

0 Likes
939

Do you have any other examples of what you are trying to achieve with this user exit?

I'm not sure I would be hard coding user names in the ABAP code. You will have to keep track of whether they get the message at every login or just once a day, and track if the message is needed again. You will need a Z table and a lock object (ENQUEUE/DEQUEUE). If you give more details of your actual requirements, we could provide you will more details and ideas.

If you want to force the user to change the password, send a list to BASIS with names and days.

USER01 password expires after 30 days

USER02 password expires after 365 days

USER03 password never expires

If you are trying to give a warning to the user...

"Your password expires in 7 days", you could do that too.

Select the records in the user tables (USR*), check the last date of password change, check the validity perdiod (expiration days), and do the math with today's date. If it's less than 10 days from expiring, display a message.

Read only

0 Likes
939

Dear friend,

As small doubt.

If we do the coding in the user-exit in order to get a warning message then it is used for only R/3 or else it will work for Portal Login also.

We have some customers who generally logon to Portal. at their system.

Is their any BADI for this.

Thanks n Regards

Vamshi Sreerangam