Introduction

Learn how to remove the “Preview” button from transaction FD03 in this blog post.

Only a screen field that has been hidden will allow this functionality to activate.

The Disable Button feature will be used based on user authorization if Table Name and Field Name are preserved.

If the table name and field name are not kept, the configured function code will perform the disable button functionality if at least one field on the screen is hidden.

Unauthorized users will see the following outcome:

Prerequisite
The “Field Masking for SAP GUI” product, which needs to be installed on the client system, is used in this case to disable buttons in SAP GUI screens.

Requirement
For transaction FD03, “Name” of Customers must be hidden according to role.

Maintain Masking configuration

Set the field’s technical information (table name–field name) for masking.

By hitting “F1” on the field, you can obtain the Technical Address of a GUI field.

Take the direction given:
SPRO -> SAP NetWeaver -> Masking Configuration -> Field Masking for SAP GUI
Maintain Masking Settings

Name

Keep the SAP GUI Function Code configured to disable buttons
For the SAP GUI’s Disable Button functionality of the chosen function code, we will configure Program Name and Function Code in this section.

Note: By hitting “F1” on a button, you can get information about a program’s name and function code under System -> Status -> Program (screen) Name and Function Code.

Program Name

Function Code

Alternatively, you can find the Program Name and Function Code information by using the following instructions –

  • Execute T-Code FD03

  • Enter Customer as “3474” and Click on “Continue” button

  • Enter /HS in the Command Field in order to switch on Debugging

  • Click on the button to be disabled. In this case, click on “Preview” button

  • Double-click on “%_CALLER_PROGRAM_NAME“, you will get the Program Name

  • Type “SY-UCOMM” and press “Enter” key, you will get the Function Code

Follow the given path:
SPRO -> SAP NetWeaver -> Field Masking for SAP GUI -> Masking Configuration-> Maintain SAP GUI Function Code for Button Disable Configuration

  • Follow below mentioned steps:
  • Click on “New Entries” button
  • Enter “Program Name” as “SAPMF02D”
  • Enter “Function Code” as “$SHO“
  • Enter “Description” as “Disable Preview button in FD03“
  • Check “Enable Configuration” check-box
  • Enter “Table Name” as “ADDR1_DATA“
  • Enter “Field Name” as “NAME1“
  • Enter “Message Class” as “/UIM/UI“
  • Enter “Message Number” as “912”
  • Click on “Save” button

Conclusion

We learned how to disable the “Preview” button in transaction FD03 in this blog post.

Please see the blog post Disable Button UI Data Protection – Disable “Additional Data” button in MM03 for details on the Disable Button feature in UI Data Protection.