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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / UpdateContext does not...
Power Apps
Unanswered

UpdateContext does not work on Dynamics New Form for Gallery onSelect

(0) ShareShare
ReportReport
Posted on by

Hi

 

- Embedded Canvas App on Dynamics Quote entity

- Used to add Quote Lines to Quotes

- Gallery of Price List Items displaying available Products with the price for the Product

- On Select of a Price List Item I would like to populate the selected product & price into the Quote Line Form

- The Form is of Type "New"

- On Select of a Gallery item, it UpdatesContext and sets the variables that are used in the Form

 

Now the issue is: sometimes the OnSelect works and fires, sometimes it doesnt.

It works in only about 20% of the cases.

 

OnSelect in Gallery:

 

UpdateContext({pricePerUnit: PriceListItems.Selected.Amount; product: PriceListItems.Selected.Product; unit: PriceListItems.Selected.Unit})
Product_DataCard.DataCardValue.Default = product
Unit_DataCard.DataCardValue.Default = unit
Price_DataCard.DataCardValue.Default = pricePerUnit

 

image.png

Any ideas why the UpdateContext doesnt update my Form?

Thanks!

Categories:
I have the same question (0)
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    Hi @Anonymous 

    As a test could you use Set() instead of UpdateContext() and see if that works?

     

    Set(pricePerUnit; PriceListItems.Selected.Amount);;
    Set(product; PriceListItems.Selected.Product);; 
    Set(unit; PriceListItems.Selected.Unit)

     

     

  • Community Power Platform Member Profile Picture
    on at

    Exact same issue. Feels it works a litte more often, but from 50 click, it works maybe 25 times.

     

     

    What is the difference between the default value of the Card vs the default value of the concrete item?

     

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    I figured out the issue.

    It happens when I click on my labels.

    All labels have Select(Parent) but it seems this is not called.

    Issue was the DisplayMode which was set to "View".

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard