Showing results for 
Search instead for 
Did you mean: 
Super User
Super User

URGENT - remove from collection if dropdown selection is blank



OnChange of a dropdown, I am doing the following... to set the chosen value to a global variable, and also add it to a collection if the selection is not blank (there is a blank Items entry at the start). 



Set(Desk1EL4, Desk4_1.Selected.Value);
Collect(FFELMulti, {deskref: If(!IsBlank(Desk4_1.Selected.Value), Desk4_1.Selected.Value), date: DeskDate1EL4});

//If(IsBlank(Desk1_1.Selected.Value), Remove(FFELMulti, Desk1_1.Selected.Value))



What I want is, if the user selects the blank value, to remove it from the collection. This way, when I patch ForAll items in the collection, it will only patch data over to Dataverse for dropdowns which are not set to blank. 


Please help. I have commented what I have tried, but this is erroring on the Remove part!!!


Many thanks


Resolver II
Resolver II

if I understood correctly, you wanted to remove items that have deskref being blank?

maybe you can try with this formula:

RemoveIf(FFELMulti, IsBlank(deskref))

Helpful resources

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Top Solution Authors
Top Kudoed Authors
Users online (2,693)