cancel
Showing results for 
Search instead for 
Did you mean: 

how to add a logon screen if the user is a guest.

Former Member
0 Kudos

hi,all

how do i add a logon screen if the user is annoymous, I use

IWDClientUser wdUser = WDClientUser.getCurrentUser();

IUser currentuser = wdUser.getSAPUser();

And I don't want to raise exception,if the user is a guest.I just want to show the logon screen to him and let him to logon.

I know if the webdynpro application is on the portal, it has no need.

But I just want to do this for test.

Is there any code to do this?

Thank you.

Best Regards

delma

Accepted Solutions (1)

Accepted Solutions (1)

former_member194668
Active Participant
0 Kudos

Hi Delma,

If you need the logon before starting the application itself, then you can set "authentication=true" in the application properties.

If you wanna show some initial content in WD and on any specific user action, if you want the user to login, then try this:

	if(WDClientUser.forceLoggedInClientUser().isAnonymousUser())
		WDClientUser.forceLogoffClientUser("<app url>");

-Aarthi

Former Member
0 Kudos

Hi,aarthi

Thank you. The problem is solved.

Best Regards

delma

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Delma,

This is not direct answer to your question. You may find your answer in the following tutorial (There are 3 tutorials)

/docs/DOC-8061#56