cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
simms7400
Level 8

ComboBox Issue - will not source a default

Hi Folks -

I'm trying to add a ComboBox to an EditForm of mine, particularly within a DataCard.

The EditForm sits on a SP List called "rdActivity".

 

Ultimately, if an end user insitaites a change request, the ComboBox needs to populate with the current data element from the "Parent_Node" SP List column from "rdActivity".

 

In the screen shot below, I have the ComboBox off to the side right now just to validate, but furture state will be the ComboBox will overlay the "Parent Node" node and then the"Parent Node" DataCardValue field will be "ComboBox2.Selected.Value"...

 

helo.jpg

 

The form right now is reading in all columns related to PFP-A1217500 thereofore the ComboBox should be populated with PFI-00590-10159 as showns in the "Parent Node" field above.

 

My ComboBox is a collection.

 

Weird that the DefaultSelectedItems validates but doesn't return anything. Any ideas? Thank you!

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: ComboBox Issue - will not source a default

@simms7400 

Yes, makes sense...I'm reviewing that from your photos now.

 

So, this begs the question...what value do RD_Target_List and RD_Investment_List play in this?  If they don't have a corresponding Parent_Node (which is what you are trying to get), then they will only have part of what you want...a name.

 

Are you saying that you want to get (let's stick with one list at the moment) all of the Name values from RD_Target_List, then find all of the Parent_Node values from the rdActivity list where the Name values are equal?

If that's the case, then you could change your formula for the collection to this:

Clear(ListActParentList); 
Collect(ListActParentList, 
           AddColumns(
               ShowColumns(
                   Filter(RD_Investment_List, Portfolio_Status<>"Terminated"), 
                   "Name"),
               "Parent_Node", Lookup(rdActivity, Name=RD_Investment_List[@Name]).Parent_Node
            )
         );
Collect(ListActParentList, 
           AddColumns(
              ShowColumns(
                  Filter(RD_Target, List,Portfolio_Status<>"Terminated"), 
                  "Name"), 
         "Parent_Node", Lookup(rdActivity, Name=RD_Target_List),Parent_Node
           )
        )

Now...some adjustment might be needed on that formula.  I'm just shooting from my head (at least not at it 😉 )

 

But, I'm not sure if that is in fact what you are looking for.  And, I don't know how that might play into any duplication or similar records.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

29 REPLIES 29
simms7400
Level 8

Re: ComboBox Issue - will not source a default

rdActivity Table:

table.jpg

Super User
Super User

Re: ComboBox Issue - will not source a default

@simms7400 

Your DefaultSelectedItems property is using a lookup, which will, in this case return a record.

Try changing the formula to :  Filter(rdActivity, Parent_Node=ThisItem.Parent_Node)

 

I hope that helps you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
simms7400
Level 8

Re: ComboBox Issue - will not source a default

@RandyHayes 

 

I used that formula but no results. One thing to note, the "Default" propery of my "Parent Node" card is a variable called "PFPParent".

The reason I do this is because an end user is directed to this from from up to (3) galleries. Therefore, I set the gallery selection to the variable "PFPParent" and then display it when I get to this form.

 

I also tried this with no luck:

act.jpg

Super User
Super User

Re: ComboBox Issue - will not source a default

@simms7400 

Are we saying perhaps that Parent_Node has no value??  If so, then possibly changing the formula to this:

   Filter(rdActivity, Parent_Node=PFPParent) 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
simms7400
Level 8

Re: ComboBox Issue - will not source a default

@RandyHayes 

 

Strange, I tried that logic as well and still no result.  This is a head scratcher...

Super User
Super User

Re: ComboBox Issue - will not source a default

@simms7400 

What is your Value display set for on the ComboBox (in the properties pane)?  Perhaps you're not seeing anything based on the chosen value.

What is the Items property set to?

Your Items property should be all the possible values you want to display in that combobox.  That really should be the Filter(rdActivity, Parent_Node=PFPParent) formula. 

The DefaultSelectedItems property will determine which ones are "selected".

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
simms7400
Level 8

Re: ComboBox Issue - will not source a default

@RandyHayes 

 

Here is my collection for the ComboBox:

Clear(ListActParentList);
ForAll(
Filter(RD_Investment_List, Portfolio_Status<>"Terminated"),
Collect(ListActParentList, Name)
);
ForAll(
Filter(RD_Target_List,Portfolio_Status<>"Terminated"),
Collect(ListActParentList,Name)
)

I wonder if the issue is the collection and the way it's returning vs how the combobox needs  it...

simms7400
Level 8

Re: ComboBox Issue - will not source a default

@RandyHayes 

 

For my ComboBox Items property, it's set to my collection:

ListActParentList
Super User
Super User

Re: ComboBox Issue - will not source a default

@simms7400 

First, does ListActParentList have any values in it?  Go into the View->Collections and look at that collection to see that it has data.  

Then, if it does, make sure the Fields of the combobox are set to Value (which should be the name of the only column in your ListActParentList collection).

If all of the above are good, then you should see values in the combobox regardless of the DefaultSelectedItems.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (5,696)