Hi All,
I have a gallery where there are two dropdowns (Phase and Work product). Work product should filter dropdown values based on the Phase selected. For E.g. If Phase selected values is "Onboarding" then the Work Product should have values only as (Code, Product, CAR Report). The Work Product values will not have only 3 constant value always. It might add more values in the future. And If CAR Report is selected for one row in the gallery it must omit that option and show the rest two values in the dropdown for the next row. E.g. If(1st row has CAR Report, then the second row should display only Code, Product in the Work Product Dropdown). These two criteria must satisfy for the Work Product Dropdown.
Any help/suggestion on this.
Thanks in advance.
If(dropdown_Phase.Selected.Phase=Label5.Text,
Filter(
Work_Product_Master,
PhaseNames = Phaseglrdropdown.Selected.Phase
).'Work Product/Process',
dropdown_Phase.Selected.Phase=Label5.Text&&!IsBlank(LookUp(DataSourceForGallery,WorkProduct=Label6.Text)),
Filter(
Work_Product_Master,
!IsBlank ('Work Product/Process')&&'Work Product/Process'<>Label6.Text
).'Work Product/Process'
)
The already selected choice is not getting omitted for the second time. I have attached the screenshot for the same. When the Product is already selected it still show the Product value in the dropdown for the next row.
I have attached screenshot of how the gallery look like. When the Project name and the Practice displayed above based on that the gallery loads with the Phase values. The Phase dropdown will not be the same for all the Projects. Based on the project name the Phase dropdown values also varies. For e.g. for the Project Demo July the Phase values will be Onboarding, design and for the another project this Onboarding value will not be there. So I cannot manually give the values for Phase too as how you gave above.
Hi @Uthhra,
Not sure how you filter phase based on project name selected, I just give you an example based on the Sort() function on Phase dropdown.
If(dropdown_Phase.Selected.Phase="Onboarding",
Filter(
Work_Product_Master,
!IsBlank ('Work Product/Process')
).'Work Product/Process',
dropdown_Phase.Selected.Phase="Onboarding"&&!IsBlank(LookUp(DataSourceForGallery,WorkProduct="CAR Report")),
Filter(
Work_Product_Master,
!IsBlank ('Work Product/Process')&&'Work Product/Process'<>"CAR Report"
).'Work Product/Process'
)
Note that DataSourceForGallery is the data source you populate the Gallery with.
Phase and Work Product column type is Single line of text in SharePoint. I have added a Dropdown for both on the screen and gave the items property of the Dropdown based on the Project name selected in the gallery.
The items property of the Phase is:
Sort(
Phase names,
Phase
)
This Phase names comes from another list called Phase master which filter the values in Phase dropdown based on the Project name selected. And for the Work Product the items property which I have given as of now is:
Filter(
Work_Product_Master,
!IsBlank ('Work Product/Process')
).'Work Product/Process'
which filter the Work Product values in dropdown from a list called Work Product Master.
Hi @Uthhra,
Please do answer my question:
I hard code this because you don't tell me how you set the Items property of phase dropdown and I don't know column type either.
And we cannot give dropdown values manually. The values of the Work product can change in the future. So it has to be filtered directly from the SharePoint list based on the Phase selected.
Phase is also a dropdown which collects value from a list called Phase master. Both Phase and Work product dropdown has two different list. If the Phase has some other values other than "Onboarding" it has to load the remaining Work product dropdown other than the three values for Onboarding.
Hi @Uthhra,
Could you please tell me thaht how you set the Items property of dropdown Phase?
What is the column type of Phase and Work product?
Generally, we could hard code the Work product dropdown based on dropdown Phase selected.
If(dropdown_Phase.Selected.Phase="Onboarding",["Code", "Product", "CAR Report"],dropdown_Phase.Selected.Phase="Onboarding"&&!IsBlank(LookUp(DataSource,WorkProduct="")),["Code", "Product"])
WarrenBelz
146,745
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
66,091
Most Valuable Professional