Quantcast
Channel: SAP Cloud Applications Studio
Viewing all articles
Browse latest Browse all 81

Problem with New Feature Mandatory error message for OnSave validation

$
0
0

Hello community,

 

If you've read the What's New on SAP Cloud Applications Studio 1608, you probably seen this.

 

Mandatory error message for OnSave validation

The system now displays an error message to the developer when a Save is rejected. There is an enhancement in the OnSave validation framework to check if any custom error messages are generated in the OnSave event while it returns false value. If not, the system displays a technical error message to explain which solution is responsible for the rejection.

 

 

Well, the problem is that you may have developed solutions and have raised some messages on the BeforeSave to improve performance or other specific reasons. In this case you've probable used a Transient flag to check if the object is valid or not. Then on OnSave you've just returned this flag, blocking then the Save.

 

In this scenario you will probably find an error message similar to this.

automatically-message-onsave.png

 

In order to remove this message, you will have to raise an ERROR message on the OnSave event. You can use something like this.

 

automatically-message-onsave-CODE.png

 

DONE! Your result should be similar to this.

automatically-message-onsave-FIXED.png


Viewing all articles
Browse latest Browse all 81

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>