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

password

Former Member
0 Likes
1,214

how do i show an * for each character key in on a parameter field on a selection screen, like password is done on the SAP logon screen?

5 REPLIES 5
Read only

Former Member
0 Likes
610

How about an input field (Text control) of the type of Password. In Java some Text controls have an attribute passwd(boolean) that when checked displays the text only as '*'.

Enjoy

Read only

ssimsekler
Product and Topic Expert
Product and Topic Expert
0 Likes
610

Hi Louis

Try the following

PARAMETERS: p_pass TYPE text20 .

AT SELECTION-SCREEN OUTPUT .

LOOP AT SCREEN .
  IF screen-name = 'P_PASS' .
<b>    screen-invisible = 1 .</b>
    MODIFY SCREEN .
  ENDIF .
ENDLOOP .

Regards

*--Serdar <a href="https://www.sdn.sap.com:443http://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.sdn.businesscard.sdnbusinesscard?u=qbk%2bsag%2bjiw%3d">[ BC ]</a>

Read only

0 Likes
610

Try this....

report  zrich_0005.

parameters: p_pass type indxpwd.


at selection-screen output.

  loop at screen.
    if screen-name = 'P_PASS'.
      screen-invisible = '1'.
      modify screen.
    endif.
  endloop.


start-of-selection.

  write:/ p_pass.

Regards,

Rich Heilman

Oops....yep.....what Serdar said.

Message was edited by: Rich Heilman

Read only

Former Member
0 Likes
610

Check this code

Password Field on Selection-screen

The following code sets a PARAMETER to be a password input field, where for security

purposes only *'s are displayed on the screen during input

i.e. Password: *******

Parameters: p_password like sy-uname.

*******************************************************

*AT SELECTION-SCREEN OUTPUT.

AT SELECTION-SCREEN OUTPUT.

loop at screen.

check screen-name eq 'P_PASSWORD'.

move: 1 to screen-invisible.

modify screen.

endloop.

http://www.sapdevelopment.co.uk/tips/security_password.htm

Please reward points and close the thread if u have got any solution.

Read only

0 Likes
610

Use this code

PARAMETERS: p_pass(10) TYPE c LOWER CASE OBLIGATORY DEFAULT 'secret' MODIF ID 111.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF screen-group1 = '111'.

screen-invisible = '1'.

MODIFY SCREEN.

ENDIF.

ENDLOOP.