what is the difference between block lifecycle event and Exception ?

what is the difference between block lifecycle event and Exception ?


hi balaji , 

Exceptions : 

An exception is an exceptional circumstance that prevents your application flow from running normally. 

For example :  when your application fetches data from an external system, and that system is experiencing a downtime.

You should raise exceptions only for exceptional circumstances and not to control the logic of your application.

When an exception is raised, the execution of the application flow is interrupted.

 exceptions in your application using the Exception Handler action flow element. For raising exceptions in your logic, use the Raise Exception action flow element.

Handle Exceptions link : https://success.outsystems.com/Documentation/11/Developing_an_Application/Implement_Application_Logic/Handle_Exceptions 

Block Life Cycle Event : 

In OutSystems , Mobile and Reactive Web Apps, the Screens and Blocks follow a lifecycle composed by a set of stages. Some of those stages are when you open the app and enter the default screen, navigate to another screen, or change the data of the screen or block.

The data of a screen or block are the following:

  • Input parameters
  • Variables
  • Aggregates and Data Actions
  • Validation messages

While implementing a Mobile or Reactive Web App, the developer can act upon those stages by using a set of event handler actions. These event handlers give the developer visibility over the screen and block lifecycle and the opportunity to implement logic when certain events occur. 

You can see and define the event handlers in the Events section of the properties editor of Screens and Blocks, or for the event handler triggered when data finished being fetched, in the properties editor of Aggregates or Data Actions.

Block Life Cycle Event link : https://success.outsystems.com/Documentation/11/Developing_an_Application/Implement_Application_Logic/Screen_and_Block_Lifecycle_Events 

I hope this will help at some point , ....

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.