Remove seconds from the dropdown display
Application Type
Reactive

Hello!


I have a table where I'm saving two fields of time, one for the beggining of an appointment and other for its end. 


I am trying to display to the user a dropdown list that shows both fields concatenated, so the range of time can be selected. To do so, I  a function on the aggregate. 


I am trying to remove the seconds displayed on the dropdown for the user:

I tryed to format the time using FormatDateTime() but it seems I can not used it on the database. Does anyone know how can I display the list not showing the seconds? I'm new on Outsystems, and have no clue so far how to solve it. 


Thanks,


Solution

Hi Bruna,

Use Hour and Minute functions, concatenating the values in a string:

Hour(AgendaAtendimento.HIDisponivel) + ":" + Minute(AgendaAtendimento.HIDisponivel) + " - " + Hour(AgendaAtendimento.HFDisponivel) + ":" + Minute(AgendaAtendimento.HFDisponivel) 

Regards

Thanks a lot José

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