web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Save fields from colle...
Power Apps
Unanswered

Save fields from collection depending on selected option

(0) ShareShare
ReportReport
Posted on by 728

I have a collection which the user can review before submitting and make any changes if required:

Capture.PNG

In this example, the location is connected to "Arbroath" campus.  If the campus is changed to another campus, I dont want to collect the Arbroath Location dropdown.  If i change this examples campus to Forfar, the location disappears but is still collected and submitted.:

Capture2.PNGHow do i reset the location dropdown  to blank if another option is selected and submitted?  The save button i have the following:

Patch(LaptopsRequest, ThisItem, {Site: Site_Drop2.Selected.Value, ACLocation: AC_Loc2.Selected.Value, GCLocation: GC_Drop2.Selected.Value, NumberRequired: Number2.Text, StartDate: Start_Date2.SelectedDate, StartTime: Start_Time2.Selected.Value, EndTime: End_Time2.Selected.Value, Recurring: Recurring2.Selected.Value, EndDate: End_Date2.SelectedDate, Notes: Notes2.Text, Click: false}); If(EditPressed, false, Collect(LaptopsRequest, {Site: "", ACLocation: "", GCLocation: "", NumberRequired: "", StartDate: Today(),StartTime: "", EndTime: "", Recurring: "",EndDate: Today(), Notes: "", Click: true}));UpdateContext({EditPressed: false}); Set(NeedSaved, false)

Basically, if Arbroath is selected, then collect ACLocation, If Gardyne is selected, then collect GCLocation and reset ACLocation, If anything else is selected reset ACLocation & GCLocation and collect all other fields.

 

 

Hope that makes sense.

 

thanks

Alistair

Categories:

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 221 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 188 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 120

Last 30 days Overall leaderboard