Reputation:
What is the best approach to update 2 combo box from a selected Combo box
SharePoint list Issue Tracker
Home Center - Lookup
Supervisor - Person or Group
Regional Manager - Person or Group
Let me know if i explain it clearly. I attach some screen shot When they select from Home Center. Supervisor and Regional Manager gets auto populated
Upvotes: 1
Views: 1298
Reputation: 146
In the Onchange property of HomeCenter combobox ,you can set a context variable like
UpdateContext({homecenter_changed:true});
and set the value of the same variable as false in the page OnVisible property as
UpdateContext({homecenter_changed:false});
Set the Items property of Supervisor ComboBox as
If(homecenter_changed = true,Filter(Issue Tracker,Home Center =HomeCenter_combobox.Selected.Home Center).Supervisor)
Similarly,the Items property of Regional Manager can be set as
If(homecenter_changed = true,Filter(Issue Tracker,Home Center =HomeCenter_combobox.Selected.Home Center).Regional Manager)
And in the OnChange property of both Supervisor and Regional Manager,update the context varaible back to false,then only the next time you change the value for Home Center,the other two values gets autopopulated properly,like
UpdateContext({homecenter_changed:false});
Upvotes: 1
Reputation:
I was able to figure it out with a Lookup function
LookUp(Centers, Title = DataCardValue10.Selected.Title, SupervisorEmail)
Upvotes: 0