Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Page-Clear-Messages method

Updated on August 16, 2022

Use the Page-Clear-Messages method to remove all property messages and certain page messages from the page identified in the Step Page column of the current step.

Caution: Use this method with care, because various application-related processing may have added the messages present on the page. Clearing a message before the cause is reported to a user or logged is not advisable.

Your application can clear messages by other means. For example, when a user submits an HTML form to the server containing input values for properties on a page, the server clears all page messages for the page, and also clears property messages for any property with submitted values (that is, any property that was touched by the user before submitting the HTML form.)

To avoid any chance of introducing invalid data into the database, design your activity to re-validate any page that was cleared of messages, before the activity attempts to save the page.

Parameters

This method uses no parameters.

Results

All messages placed by the Page-Set-Messages method on the step page are deleted.

Messages placed by Constraints rules, edit validate rules, and property type validation are not cleared — they are cleared and the restrictions are detected only when the property value changes.

Checking the method status

This method updates the pxMethodStatus property. See How to test method results using a transition.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us