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

Message type E in PBO

Former Member
0 Likes
2,869

Hi All,

I have a dialog program that lead to a scenario where i should have to display the message type E at PBO. As understand by using message type E in PBO will lead to message display in a popup with a EXIT button on the popup itself. And once i click on the EXIT button, it will leave the program.

I'm here to get your advice on how can i display the message type E in PBO on the <u>status bar</u> (as message launch in PAI) instead of popup. Is there a way to achieve?

Please comment.

Thanks in advance.

1 ACCEPTED SOLUTION
Read only

former_member378318
Contributor
0 Likes
2,057

Hi,

You can use the MESSAGE command with the addition DISPLAY LIKE:

MESSAGE s000(xxx) DISPLAY LIKE 'E'.

This will display a message that looks like an Error message but does not behave like one.

Hope it helps.

10 REPLIES 10
Read only

former_member378318
Contributor
0 Likes
2,058

Hi,

You can use the MESSAGE command with the addition DISPLAY LIKE:

MESSAGE s000(xxx) DISPLAY LIKE 'E'.

This will display a message that looks like an Error message but does not behave like one.

Hope it helps.

Read only

0 Likes
2,057

Hi Surbjeet,

Thanks for your reply. FYI, i did tried on the additional command "DISPLAY LIKE 'E'. " with Message statement, but it can not get through the syntax check.

FYI, im working in 4.6C. Please comment.

Thanks in advance.

Read only

0 Likes
2,057

declare a flg type C.

intialise it to ' ' Space.

once u enter the transaction then in the PBO after that validation point make the flg = 'X'.

and change it accordingly in ur PAI according to the validations required.

Regards

Gopi

Read only

0 Likes
2,057

Hi Gopi,

Thanks for your suggestion, however i have to perform the validation at PBO but not PAI. It is due to some technical reason where i can not code it under PAI.

May i know how can i code the Type E message in PBO with identical behavior as we declare under PAI.

Please commnent.

Thanks and best regards,

Meng Keat.

Read only

Former Member
0 Likes
2,057

Is it possible the user has the Dialog Box option selected for Error Messages?

From the Application Tool Bar choose Customize Local Layout (Alt + F12). Then Options. Then Options tab. If "Dialog Box at Error Message" is checked, you could remove it.

Read only

Former Member
0 Likes
2,057

I think you can use function module 'POPUP_TO_INFORM' to create your own pop-up's in which you can define buttons to decide whether to stay in screen or leave the screen.

Hope this helps.

Regards,

Sail

Read only

Former Member
0 Likes
2,057

please try with this code .

if sy-subrc ne 0.
      message e030(messege class).  message  class  or  your message
    endif.

definitely it will display inthe status bar in the Red color and it is an error message.

Girish

Read only

0 Likes
2,057

Hi Girish,

Thanks for your reply. FYI, i have no problem on syntax for how to launch a message with type E. Please read my initial post where i did mentioned my difficulities while im launching type E message in PBO.

Thanks in advance.

Read only

0 Likes
2,057

You say "It is due to some technical reason where i can not code it under PAI."

If this is true then under certain circumstances your code in the PBO may never get hit and therefore your check and error message will never get displayed. For instance if the user presses SAVE or NEXT SCREEN the PAI will be hit for sure but from there you may either leave the transactioon or leave to another screen (so PBO of current screen will never get hit). It is guaranteed your code will be hit at least once on first entry to the screen, not after.

If you insist then perhaps you can display a success/warning message with text begining "E: This is an error". Its not an error message but the E: may convice the user that it is?

Read only

Former Member
0 Likes
2,057

Hi,

Even if you give an error message in the status bar you will not be continue with the transaction..

Thanks,

Naren