cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
moltenlava
Frequent Visitor

Set field powerapps issue

Hi,

 

I am fairly new to PowerApps so i dont know what im missing here. I have a Powerapp that links to a sharepoint list. The first page gives the user three buttons/options which is to "book an innovation workshop", "book a consulting workshop" and so on. When they click each button it takes them to a page where specific columns from my sharepoint list show up (ones related to each workshop type). 

 

There is a field in my sharepoint list called "Type of Workshop". To remove duplication, i want the "type of workshop" field to be automatically populated with whatever button type they clicked.

 

I have tried Patch, Microsoft Flows, UpdateContext and i still can't seem to get it right.

 

Any help will be appreciated!! 🙂 

 

Thank you.

1 ACCEPTED SOLUTION

Accepted Solutions

I have found a solution!

 

I worked around it by instead setting the data card as a default value and then hiding it from the edit form

 

I set the data card default.selected as:

 

If(EditForm1.Mode = New, {'@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
   Id:0,
  Value:"w"}, 
Parent.Default)

 With W being the drop down i want it to be 🙂

 

Thanks for your help anyway!

View solution in original post

7 REPLIES 7
KickingApps
Skilled Sharer
Skilled Sharer

If you have 3 buttons, do something along the lines of:

Button1
OnSelect = UpdateContext({ThisButton:Button1.Text})

Button2
OnSelect = UpdateContext({ThisButton:Button2.Text})

Button3
OnSelect = UpdateContext({ThisButton:Button3.Text})

Set the text property of field you want to auto populate with:

ThisButton

Hi Kicking Apps,

 

Thanks for the response! I'm fairly new to PowerApps so please correct me, but i put in your formula in my first button and unsure what you mean by update text property of the field? How would i go about that?

 

Attached pictures showing my attempted formula for the first button and what field i want updating:

@moltenlava Check out the attached to see if it will work for you.  Instead of 3 buttons, I used a gallery with one button and name the buttons from the collection (refer to the OnStart sim button).

 

I added a dropdown control that provides the user the choices from the collection but will default to whatever is selected from the gallery.  

Hi Kicking apps,

 

Any way this can be sent as an image? I don't have the desktop app so the file wont open properly.

 

Thank you!

Did you download the file?  If so, go to create.powerapps.com and browse for the downloaded file.  Select the file and it should open in the PowerApps web browser.

I have opened it - thanks!

Will this solution work if the dropdown is a SharePoint field?

Also if the onstart button is on page 1 and the three buttons in the gallery on page 2 for example?

I need the formatting of my screens to be the same as the image.

 

Sorry about the confusion!

I have found a solution!

 

I worked around it by instead setting the data card as a default value and then hiding it from the edit form

 

I set the data card default.selected as:

 

If(EditForm1.Mode = New, {'@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
   Id:0,
  Value:"w"}, 
Parent.Default)

 With W being the drop down i want it to be 🙂

 

Thanks for your help anyway!

View solution in original post

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

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