2008 May 27 5:25 AM
Hello Everyone,
I am using MB_MIGO_BADI , im using metho item_modify for checking data at item level, and displaying error message when ever the check condition fails.
When ever the required conditions fail, i am displaying a pop-up message.
This is all what i did so far.
Now my problem is, when my conditions fail, i want to exit the program and my message should be displayed. But now it is just displaying the message as warning. It should be a error message.
I am using 'POPUP_TO_INFORM' function module for POP UP.
Thanks in adavance.
Regards
Ravi
2008 May 27 7:06 AM
Hi Ravi,
use leave to screen sy-dynnr
sample code..
IF sy-subrc <> 0.
CALL FUNCTION 'POPUP_TO_INFORM'
EXPORTING
titel = 'Authorisation'(007)
txt1 = 'You are not authorised or'(008)
txt2 = 'Check your password'(009).
LEAVE TO SCREEN sy-dynnr.
ENDIF.
else.
CALL FUNCTION 'POPUP_TO_INFORM'
EXPORTING
titel = 'Password Check'(010)
txt1 = 'Password is Blank or'(011)
txt2 = 'Check your password'(009).
LEAVE TO SCREEN sy-dynnr.
endif.
ENDIF.
endif.
Regards
Kiran Sure
2008 May 27 7:16 AM
Hiii Kiran,
It says an error " SET SCREEN NOT ALLOWED IN SUB SCREENS ".
this errors came after my pop up is displayed.
Regards
Ravi
2008 May 27 7:18 AM
Hi,
You can look at the examples.
Transaction: ABAPDOCU
-->ABAP User Dialogs
--->Complex Screen Elements
-
>Subscreens
Regards
Kiran Sure
2008 May 27 8:21 AM
POPUP_TO_INFORM is a function module to display information and this is normally done using a popup window. If you want to display information as error message try using command message e(XXX) directly in the code of the Implementation.
2008 Jun 19 9:07 AM
My problem is solved.
solution is:
I had passed a parameter from item_change method to check_item method in MIGO_BAdi.
there by using that parameter i had created an error msg in check_item method.
Thanks for ur help
Regards
sunil