getting values to a variable in a expression from multiple screen
Question
Application Type
Reactive

I have a variable inside an expression.It's calculated on screen. But when this screen gets called from the main screen the values should get populated from that screen. how to achieve that

Room.RoomNumber + " at " + Room.Price + "$ per night"

this is the main screen for the above page.

the values are not getting populated ; as it is generated locally.

HotelRukku.oap

Solution

Hi Rukkunudeen Rahmadhullah,

As I can see in your OML, Your not assigning any value for Room variable when the screen navigates to the booking detail screen.  Please try to follow the below approach, hope this Helps.

URL : https://saravanan-gamechanger.outsystemscloud.com/RukkusHotel/Booking?_ts=637644533711181990

Regards,

Saravanan Santhanam.

RukkusHotelUpdated.oml

thanks a lot. got the logic; create an aggregate and pass the values from aggregate to the screen values

Hi Rukkunudeen,

You can use OnAfterFetch of  GetBookingByID aggregate in BookingDetail screen and calculate the Number of Rooms and  Price for Room and assign the Value for Room Variable.

Create a Screen Action and assign the value for Room Variable create in Bookingdetail screen

Room.Price= <calculated values from Aggregate>

Room.RoomNumber=<Calculate the number of rooms using aggregate>


Dileep

I am able to get the values from the booking detail screen and populate it, But I am not able to do it from the booking screen (when I click the row in booking and it redirects me to booking detail); even if I get the values from the booking screen; how to populate it to the same expression and variable in the booking detail screen. (This is the issue here)


Solution

Hi Rukkunudeen Rahmadhullah,

As I can see in your OML, Your not assigning any value for Room variable when the screen navigates to the booking detail screen.  Please try to follow the below approach, hope this Helps.

URL : https://saravanan-gamechanger.outsystemscloud.com/RukkusHotel/Booking?_ts=637644533711181990

Regards,

Saravanan Santhanam.

RukkusHotelUpdated.oml

thanks a lot. got the logic; create an aggregate and pass the values from aggregate to the screen values

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