Function-'popup _ to_confirm'

Source: Internet
Author: User

A pop-up dialog box is often required in SAP to remind customers whether they want to perform an operation. We can call function 'popup _ to_confirm'

The following describes common parameters.

DATA: G_RETURN type c.

Call function 'popup _ to_confirm'
EXPORTING
* TITLEBAR = 'pop-up title'
* DIAGNOSE_OBJECT = ''" diagnostic text (maintained by SE61)
Text_question =
* TEXT_BUTTON_1 = 'text on the first button'
* ICON_BUTTON_1 = 'icon on the first button'
* TEXT_BUTTON_2 = 'text on the second button'
* ICON_BUTTON_2 = 'icon on the first button'
* DEFAULT_BUTTON = '1'
* DISPLAY_CANCEL_BUTTON = 'X'
* USERDEFINED_F1_HELP =''
* START_COLUMN = 25
* START_ROW = 6
* POPUP_TYPE =
* IV_QUICKINFO_BUTTON_1 =''
* IV_QUICKINFO_BUTTON_2 =''
IMPORTING
ANSWER = G_RETURN "return parameters: click the first button to return '1'," click the second button to return '2 ',

"Click the third button to return to 'A ',
* TABLES
* PARAMETER =
* EXCEPTIONS
* TEXT_NOT_FOUND = 1
* OTHERS = 2
                                       . 

My simple usage is as follows:

* ** In the pop-up window, check whether the delete operation is performed.
CONCATENATE 'Are you sure you want to delete the data' INTO g_string1. "prompt message
Call function 'popup _ to_confirm'
EXPORTING
Text_question = g_string1
IMPORTING
Answer = g_return.

IF g_return = '1 '.
MODIFY TABLE_NAME from table TABLE_WA. "confirm operation
MESSAGE 'deletion operation confirmed! 'Type '.
ELSEIF g_return = '2' OR g_return = 'a '.
MESSAGE 'deletion operation canceled! 'Type '.
ENDIF.
ENDIF.

Result chart:


Attached function parameter diagram:


Function-'popup _ to_confirm'

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.