I have a dropdown with these properties:
Items:
Filter(Organizer,Title = LookUp(ExpenseReport, VersionNumber = Label10.Text).Region).NameOfTutor
Default Selected Items:
{Value : LookUp(Filter(ExpenseReport,VersionNumber=GroupOfRecords.Selected.VersionNumber), OrganizerType= "Lead Organizer",'OrganizerName')}
This dropdown will update an item in a certain column in my DetailsGallery.
Where when a Gallery Item have an Organizer Type of "Lead Organizer", it will copy the name that has been selected. There's a button that will update the sharepoint list for the changes.
The textinput property have this on Default :
If(OrganizerType.Text = "Lead Organizer",Record_Organizer.Selected.NameOfOrganizer,OrganizerType.Text = "2nd Organizer",Record_2ndOrganizer.Selected.NameOfOrganizer)
Issue:
When I open the page where my Galleries are, the initial Organizer resulted from the Defaultselecteditem of the dropdown is not showing in the Details Gallery. It will only show the name if I really selected it.
Then I need to repeat the question - if the Items of the Combo Box is
Filter(
Organizer,
Title = LookUp(
ExpenseReport,
VersionNumber = Label10.Text
).Region
).NameOfTutor
the output cannot be .Value on a Classic Control - it is displaying the field NameOfTutor
That is Classic Themes, not controls
Will it still work if the classic is now in Retired?
That explains the .Value, but I have not delved into Modern Controls to any extent at this stage and their capabilities seem limited in many ways compared with Classic. Happy to help if you revert to Classic, but I am not the best person to debug modern controls that do not work as expected.
Sorry.
I explain again. Its Modern Control
On my screen there are:
2 comboboxes:
2 Galleries
Properties of the Comboboxes:
Record_Lead:
Item: With(
{Region: LookUp(MFBudgetCalculator,VersionNumber = GroupOfRecords.Selected.VersionNumber).PMU_BC},
Filter(MFTutorsPerPMU, Title = Region).NameOfTutor)
DefaultSelectedItems:
{NameOfTutor : LookUp(Filter(MFBudgetCalculator,VersionNumber=GroupOfRecords.Selected.VersionNumber), TutorType = "Lead Tutor",'Tutor Name')}
Record_2nd:
Have the same Item Property
DefaultSelectedItems:
{NameOfTutor : LookUp(Filter(MFBudgetCalculator,VersionNumber=GroupOfRecords.Selected.VersionNumber), TutorType = "2nd Tutor",'Tutor Name')}
Current Issue:
Default selected item is blank, it's not showing any name. But if I replace the 'NameOfTutor' to Value, it shows the Name as intended.
Details Gallery Property:
Items:
SortByColumns(Filter(Filter(MFBudgetCalculator,VersionNumber=GroupOfRecords.Selected.VersionNumber),'Expense Group' = "Fixed Cost"),"ExpenseType",SortOrder.Ascending)
Expense Name | Tutor Type | Tutor Name | Currency | Amount |
Fees | Lead Tutor | Carl | GBP | 5000 |
Fees | 2nd Tutor | Grace | EUR | 8000 |
Conference Cost | USD | 30000 | ||
Materials | USD | 200 |
Details Gallery texinput names:
Record_ExpenseType
Record_Tutor
Record_Name
Record_Currency
Record_Price
Record_Name Default property:
If(RecordTutor.Text = "Lead Tutor",Record_Lead.Selected.NameOfTutor,RecordTutor.Text = "2nd Tutor",Record_2nd.Selected.NameOfTutor)
Current Issue:
The result in the default selected item of the comboboxes is not showing in the Record_Name text input. It needs to be selected first before it show. I also want the result of the default selected item of the comboboxes to show in this text input not only what was selected.
OK - some of what you posted is not clear to me if that is the result. The DefaultSelectedItems have two elements - the first is the output of the Combo Box (ComboBox.Selected.xxxx) and the second is the value you want to display in it. So if Value is the output, how can the Items be
Filter(
Organizer,
Title = LookUp(
ExpenseReport,
VersionNumber = Label10.Text
).Region
).NameOfTutor
as this would result in an output of NameOfTutor, which is what I posted.
Also before we go any further, is this a Classic or Modern control ?
Hi @Curiosity_user ,
I would have thought that a Combo Box with the Items (note I have made a suggestion here to solve your Delegation issue)
With(
{
_Region:
LookUp(
ExpenseReport,
VersionNumber = Label10.Text
).Region
},
Filter(
Organizer,
Title = _Region
).NameOfTutor
)
should have the DefaultSelectedItems of (also you do not need both Filter and LookUp)
{
NameOfTutor:
LookUp(
ExpenseReport,
VersionNumber = GroupOfRecords.Selected.VersionNumber &&
OrganizerType = "Lead Organizer"
).'OrganizerName'
}
and the output to reference would be
ComboBoxName.Selected.NameOfTutor
Is this what you are asking ?
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
MVP (Business Applications) Visit my blog Practical Power Apps
WarrenBelz
146,524
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,906
Most Valuable Professional