I have a SharePoint list of records as shown below format
{
menu_name: "Home"
screen_name: "Home Screen"
},
{
menu_name : "Task"
screen_name : "Task Screen
}
I understand that `Navigate()` doesnt take string as input parameter.
So as I work around,
I wanted to iterate over this table( menuTableList) and use if() to check if screen_name is "Home Screen" if yes I need to update the screen_name of this table collection with actual Home Screen control.
how to write the formula for this? I dont know how to loop over and do a conditional check and update the record.
NB: I have navigation componenet which accepts screen and navigate if the user clicks on some icons.
-----
Detailed explanation
I understand that point, What I am trying to ask is that if I have a collection in the following format
{
menu_name: "Home"
screen_name: "Home Screen" // Screen Name String
},
{
menu_name : "Task"
screen_name : "Task Screen // Screen Name String
}
How can I modify this collection to replace screen name string with actual screen control? ( I understand that this can be done with a switch statement ie. A switch that accepts string name from the initial collection and modifies it with the actual screen control.)
{
menu_name: "Home"
screen_name: 'Home Screen' // Screen Control
},
{
menu_name : "Task"
screen_name : 'Task Screen' // Screen Control
}
Since I am new to PowerApp Im not getting how to code this out. My logic
- Iterate over initial collection
- for screen_name initiate switch case
- replace string with actual screen control
- return the collection
Could you please help me to code this?