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

How to return error message using macro or others ways

Former Member
0 Likes
1,001

Hi !

I need your help to find a technical solution.

We have an alv object with 2 parameters (a checkbox and a writable field which is for address mail.) When you push the button B1, the function module SX_INTERNET_ADDRESS_TO_NORMAL is called to verify the email address.

If I use the classic way to show the exceptions returned by the function module, the user can read the message but when he does an action on the program this dump. (The program has been killed.)

I am looking for a way to show the error message and the possibility to change the email address. I think that using a popup information would work but I do not find this way very nice. Can I use macro to have the message on the status? In positive case, could you explain me how to use it?

Thanks!

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
824

try BCALV* demo codes. you will get solution for this.

any ways. this function module must be having exceptions.. right? use this exception to populate a Information message(default is error). then deal with it.

try BCALV* demo codes. you will get solution for this.

any ways. this function module must be having exceptions.. right? use this exception to populate a Information message(default is error). then deal with it.

3 REPLIES 3
Read only

Former Member
0 Likes
825

try BCALV* demo codes. you will get solution for this.

any ways. this function module must be having exceptions.. right? use this exception to populate a Information message(default is error). then deal with it.

Read only

Former Member
0 Likes
824

I found a way which is not very helpful^^.

In the standard the instruction "Message e456 with <wrong address>' is visible in a popup but if you put the same instruction in a program test this instruction shows the message in the status barre. (Program SAPLSO04)

Why?

Read only

0 Likes
824

check the context in which the message statement is running, [here in sap library - message processing|http://help.sap.com/saphelp_nw2004s/helpdata/en/9f/dbaae335c111d1829f0000e829fbfe/frameset.htm], you will get the answer why!