MOBILE: Get the data from a weblock

MOBILE: Get the data from a weblock

  

Hi Community!


I'm trying to get/retrieve the data from a weblock using the "Trigger Event" in mobile and I'm trying to follow this one but I'm not sure how I'm gonna receive the data in my parent screen. I know I'm missing something here. This is my first time using the trigger event in mobile.


The data that I'm trying to retrieve from a weblock is a variable record list, I'm not saving any data in an aggregate yet just passing values/data.


I hope my explanation is not confusing. Hope to hear from you guys soon! :)


Thank you!


Kind regards,

Louise

Solution

Hi Louise,

When you add an Event to a Block and use that Block in a Screen you will have to specify a Client Action that handles that event.

If the Event has input parameters, those input parameters will also appear in the Client Action.

When you "raise" that event (by calling it in some action) in your Block you will fill the values for its input parameters. Those values can then be read in your Client Action of the Screen.

Cheers,

José

Solution

Hi José,


Thank you for replying! I got it now thanks to your explanation. I missed adding an input parameter in the client action that handles the event and also I kept using an On Render client action as a handler which kept on giving an error, my bad.


Thank you so much for the help! :)


Kind regards,

Louise

José Costa wrote:

Hi Louise,

When you add an Event to a Block and use that Block in a Screen you will have to specify a Client Action that handles that event.

If the Event has input parameters, those input parameters will also appear in the Client Action.

When you "raise" that event (by calling it in some action) in your Block you will fill the values for its input parameters. Those values can then be read in your Client Action of the Screen.

Cheers,

José


Hi Jose,

In my mobile app, I am using a webblock to search list of airports and select the desired one in my screen(Trip screen) to create/edit the trip. I am able to select and save the result in the database in Create mode. Now when i want to edit the data in Edit mode, i want to have this selected airport been set to the webblock.

I tried creating an onInitialize event where i am setting these default values. I am getting all the fields in the screen set except this webblock. may be i am missing something here

can you please help me.

thanks,

-Venkata Rajam