Get the contents of the record from a list.

Using this output parameter, I know which record is being clicked on in my mobile application.


I'm new to outsystems and I have no idea how to get the value of an element (field) when I click on the item of the list.

As I know the CurrentRowNumber, I would like to get the value for example from the element (field) tasks that is in the CurrentRowNumber, which I am showing below, that is, I want to get the value "Café".


Can you teach me step by step?

Thanks.

Marcelo Sampaio

Solution

Hi Marcelo,

You can follow below steps to get that.

Easy and fast way.

1-  Create Producao1Data entity

2- Go to Main UIFlow, Drag the entity to mail UIFlow, this will create two screen for you one is list screen other one is list details screens.

3- Now once you click on any list item it will open that record in detail screen.

But in your case.

1- First create a mobile screen and right click k and get data from Database.

2- Drag the aggregate GetProducao1Data to screen.

3- Create a Onclick action on ListItem.

4- Under action to get the current row value by using

GetProducao1Data.List.Current.Producao1Data.Tadefas

Hope this will help you.

Dileep.

Dileep,

I followed your procedures and it worked perfectly...

Just to make it clearer to other users who need the same help, the detailed procedures I followed were:


1- To get the value of a record in a list, it is necessary to create a ListItem on a screen.

2-Inside this ListItem (on the left) it is necessary to create a List.

3-Inside this List, we will place the table with the data, which will create the AGGREGATE and in the ONCLICK event of the ListAction, we will create a local variable (integer) of the created screen and assign the value of this variable:

Aggregate.List.CurrentRowNumber + 1 (this will get the current item).

In my case, I created a button to pass the information of the current item and on this button, I created one more local variable (text) the screen created and assigned the value of this second variable:

Aggregate.List.Current.Table.Tasks (which is the field I needed to get).



Thank you very much Dileep.

Great! Glad to know you are able to solve it. Happy coding...:)

Cheers happy weekends!

Dileep

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