Skip to main content

Notifications

Power Platform Community / Forums / Building Power Apps / Update property on a c...
Building Power Apps
Suggested answer

Update property on a card with a combobox

Posted on by 182
Hello,  i am trying to set up a cascading combo box selection so that the second combobox changes it's values based on the selection of the first.  My data is in dataverse and i have a table set up that defines the relationship between the first value and second value, in TMarkets.  The problem that i have is when i updated the Items property, i now get an error in the update property, "Name isn't valid, value isnt recognized" 
 
 
This is what i have under update: DataCardValue34.SelectedItems.Value
 
This is the current items for the second combo box:   Filter(TMarkets, LineOfBusiness in LOBSelect.SelectedItems
originally the items was: Choices('Geography (TMains)')

what do i need to change in the update property to save the data after an update is made?  
 
 
 
  • timl Profile Picture
    timl 31,547 on at
    Update property on a card with a combobox
    Hi Frac
     
    Can you confirm the control type of DataCardValue34? Is it definitely a combobox, because Selected should certainly be a valid property of a combobox control?
     
    If you could find it in the designer and give a screenshot, that would help.
     
  • Frac Profile Picture
    Frac 182 on at
    Update property on a card with a combobox
    Hi @Timl, DataCardValue34.Selected.Value give me an error that copilot describes as "The expression was intended to retrieve the value of the selected item in DataCardValue34. However, the errors are that 'Selected' is not a valid property for DataCardValue34 and the '.' operator cannot be used on Error values."
  • timl Profile Picture
    timl 31,547 on at
    Update property on a card with a combobox
    Hi Frac,
     
    The crux of the problem is that the SelectedItems property returns a table (a combobox can have multiple selected records).
     
    From your description, it looks like you've currently set Geography to a text field. Therefore, if you reference the Selected property rather than SelectedItems, that should hopefully take you further.
     
    Note that you might need to change .Value to the field name if you've modified the Items property of the combo to call Filter.
    DataCardValue34.Selected.Value
     
     
     
  • Frac Profile Picture
    Frac 182 on at
    Update property on a card with a combobox
    Hi FLMike,   here is the error.    When i change the selection in LOB Impacted my Geography box updates,  but i cant save the geography selection.  I've tried to make geography a choice field and a text field, and either way i cant get it to work.  
     
    I was following a video on cascading combo boxes and i think my items properties are correct, becasue they appear to be doing what i want them to,  but the video example was not a control inside a form data card,  and i think thats part of why i'm stuck here.
     
    at the end of the day i guess i dont really care what type of field i am saving into as long as i can save and edit it.
     
  • Suggested answer
    FLMike Profile Picture
    FLMike 26,301 on at
    Update property on a card with a combobox
    Hi,
     
    You didn't actually share the code that is giving the error. Can you please do that
     
    I can tell you that there is a big difference between the two things you places in the Items property. In the first place you added records from TMarkets, after that changed it to a Collection of Choices, they are very different.
     
    Now, is your intent to update a Column that is a Choice or a lookup or a string or what?
     
    Updating a Lookup is different than updating a Choice (even if its multi-select choice), which I am not sure yours is.
     

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

September 2024 Newsletter…

September 2024 Community Newsletter…

Community Update Sept 16…

Power Platform Community Update…

Welcome to the new Power Platform Community!…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 141,122

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,414

Leaderboard