I've created a dropdown list
Items forumula:
Filter('OneEng Candidates', cr818_OneEngEvent.cr818_oneengeventid = DropdownEvent.Selected.cr818_oneengeventid)
I set the default value to the dropdown as: "" or "test" but it still keeps showing as the first item in the Items formula filter
Why is that? Does the formula override the Default? Do I need to save the app and reload?
Solved! Go to Solution.
@morall
I can help you with this 🙂
You'll have to create a collection in the and add a blank option. Do this by creating a collection.
You'll probably need to create the collection in 2 places: OnVisible property of the app and the OnChange property of DropdownEvent.
ClearCollect(colDropdownOptions, {your_column_name: Blank()});
Collect(colDropdownOptions, Filter('OneEng Candidates', cr818_OneEngEvent.cr818_oneengeventid = DropdownEvent.Selected.cr818_oneengeventid).your_column_name;
Then refer to the collection in the Items property of your dropdown.
colDropdownOptions
A similar concept is shown in this example:
---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."
@morall
I can help you with this 🙂
You'll have to create a collection in the and add a blank option. Do this by creating a collection.
You'll probably need to create the collection in 2 places: OnVisible property of the app and the OnChange property of DropdownEvent.
ClearCollect(colDropdownOptions, {your_column_name: Blank()});
Collect(colDropdownOptions, Filter('OneEng Candidates', cr818_OneEngEvent.cr818_oneengeventid = DropdownEvent.Selected.cr818_oneengeventid).your_column_name;
Then refer to the collection in the Items property of your dropdown.
colDropdownOptions
A similar concept is shown in this example:
---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."
Just out of curiosity, the default is meant to select the default item from the list, not necessarily add create new items?
Yes, that's correct. Your observation is the reason why we cannot default to blank if its not already within the dropdown items as an option.
---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."
I threw this in App and ran Run On Start:
ClearCollect(colDropdownOptions, {Name: "Morgan"});
Collect(colDropdownOptions, Filter('OneEng Candidates', cr818_OneEngEvent.cr818_oneengeventid = DropdownEvent.Selected.cr818_oneengeventid).Name;
But only "Morgan" is showing up. I would have expected it to "combine" Morgan with the rest of the options. Can you see what I'm doing wrong
Was missing a ")"
This is causing an error now on my Patch when trying to update an entity with the values in the dropdown menus:
The Patch code on a Button
ForAll(
Gallery4.AllItems,
Patch(
'OneEng Candidates_Interviewers',
Defaults('OneEng Candidates_Interviewers'),
{
Candidate: Slot1.Selected,
Interviewer: Interviewer,
IVSlot: Value(Label_Slot1.Text),
Event: DropdownEvent.Selected,
MorningOrAfternoon:drpdownMorA.Selected.Value
}
)
);
ForAll(
Gallery4.AllItems,
Patch(
'OneEng Candidates_Interviewers',
Defaults('OneEng Candidates_Interviewers'),
{
Candidate: Slot1.Selected,
Interviewer: Interviewer,
IVSlot: Value(Label_Slot2.Text),
Event: DropdownEvent.Selected,
MorningOrAfternoon:drpdownMorA.Selected.Value
}
)
);
"Invalid Argument type. Expecting a record value, but of a different schema."
Is this because previously it was looking at records in the dropdown, but now it's looking at a collection?
The table I'm patching this into is expecting a record value and it seems when I create a collection, it strips away the record value. Is there a way to handle this?
as a hack, not sure if there is a better way to do this:
Candidate: First(Filter('OneEng Candidates', Name = Slot1.Selected.Name))
The collection is returning a name, and I am trying to use that name as a filter on the 'OneEng Candidates' table, (the one I started with), and return the first record
User | Count |
---|---|
183 | |
108 | |
88 | |
44 | |
43 |
User | Count |
---|---|
226 | |
108 | |
105 | |
68 | |
68 |