How i get the days of week to buttons
Question

Hello, I have a static entity with days of week and i want to call them to the 6 buttons that i have


The first day is always the

DayOfWeek(CurrDate())


For example today is monday.

 i want to display in buttons:


Monday, Tuesday, wenesday, thursday, friday, saturday

mvp_badge
MVP

Hi Bruno,

can you let us know your use case , there is many ways you can do it

you can set like

if(DayofWeek(currdate())=1,"Monday",if(DayofWeek(currdate())=2,"Tuesday","Wednesday")) and so on.


Also you can add static label and pass input as 0 for Sunday, 1 for Monday  and so on...

Outsystem provide value of day from DayofWeek() function.


Hope this will help you.

Regards
Rahul

Hi Bruno,

using DayOfWeek function will require to map the result of the function to some attribute in the static entity. I used the Order attribute for that.




Now create a screen with 2 variables, DayList (Text List) and IsTodayFound (boolean):

UI is a List Records:


In Preparation:


Let me know if you have more questions.

Best regards

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