Forum Discussion
Collection not populating
- Apr 18, 2022
Hi ADumith , I downloaded and imported your app. I refreshed the source data to be my SP list and used the collection and filter elements I've shared and it seems to work fine. I would encourage annotating references wherever possible.
My SP list is structured like this:
My date source in the app is targeted at the list:
The 'OnStart' property is set to:
The gallery items is set to:
The first of your gallery fields is set to:
The second of your gallery fields is set to:
Without access to your source list I'm unsure what may be wrong at your end. I can use your app, redirect it and modify a few of the field names/targets and it appears to be working.
Hi ADumith , I can see now what's happening. The import from Excel brought in the Mbirth data with a field name of 'field_4'. Even if you rename it, in a Flow you need to use the original name. The original name can be seen if you view your list settings, then hover over the field in question At the bottom of the screen you will see the URL for that field with the original name at the end of the URL.
I avoid importing from Excel if at all possible but I appreciate it can sometime be a quick way to import data. A method which provides for greater control is to import the Excel data into an Access database, do any data cleansing there, and then export to your SP site as a list.
I can also see that you date of birth field is set to 'single line of text'. Should that not be a date field?
If your Mbirth data is in 'field_4' your gallery items should be set to:
//filter the gallery items to only show those with a birth month matching the current month
Sort(Filter(colBirthDay,field_4=varMonth),field_3,Descending)
Hello jonlake,
At first I thought that was the problem and it would be enough to do what you are recommending me; actually, that was what I was doing, but unfortunately that's not the problem.
I'll explain, I took the variable varMonth and assign the value 01 (January) and the filter worked!
The filter worked finally, so the problem is when I try to do the filter with the variable value or the field value, somehow there is no match between them.
Maybe if we change the type of the variable, I mean use a local one instead of global, or there is definitely a problem with the list and I have to redo it but from scratch, instead of importing it.
Any ideas?