151
Views
6
Comments
Logic to show the content in one table

This is a reactive dynamic form table where in the field data table, in label column, it displays the field names and in the FieldData Data table, displays the value of that field names passing fieldId as a reference. I need to show the detail in a tabular format where Columns having the label in it as Email, Name, and Image and Rows have their corresponding value as in Email, it display's first person email and then second person and same for all other fields.

I am using expression as a field name and it will take the current Label only but I want to display other labels also apart from the current one. Can anyone send me the logic how to do show the label as an attribute and its data in a row and also identify which data is corresponding to which attribute then accordingly display the data below that attribute.




outsystems_SS.png
2024-10-09 04-44-30
Bhanu Pratap

Hi Chetna,

You can directly use scaffolding as well by dropping the entity directly to screen it will create a table.

Other than this regarding your problem you can use:

  •  For Email - GetFields.List.Current.FieldData.TextValue
  •  For FileName - GetFields.List.Current.FieldDataFile.FileName
  •  For Image - GetFields.List.Current.FieldDataFile.Binary
  •  And Give the table headings in expressions as "Email", "File Name", "Image"

For your reference I have made a sample OML file. You can see how data is displayed on screen.

Hope it resolved your issue.

Sample.oml
UserImage.jpg
Chetna Upadhyay

It is a dynamic form table so in the UI where we display data in tabular form, the attribute name or the table header should not be pre-defined by me it should be taken from the field data table which contains the attribute names and they can be different for different dynamic form. So how can I do this?

2024-10-09 04-44-30
Bhanu Pratap

It does take table header from aggregate only. I'm attaching one file just refer it. 

3 - List and Detail Screens Exercise How To.pdf
UserImage.jpg
Chetna Upadhyay

I want to display the table header from another table field. How can I do this?

2024-10-09 04-44-30
Bhanu Pratap

Yes, you can do that just use an expression in header and give the value that you want to display as header from the aggregate.

UserImage.jpg
Chetna Upadhyay

Can someone tell a query to fetch both the Name and Email values from the table in a single output, i.e., having two columns. I am using structure to store the output but I need to create two structures and run two queries, one to fetch all the names and other to fetch all the email values. Can anyone tell me how to do this using a single query and store in a single structure instead of two. 

This is the query which I am using to fetch the name or email.

SELECT {FieldData}.[TextValue] FROM {FieldData} WHERE {FieldData}.[FieldId]=@FieldId

I am taking fieldId as an input parameter.


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