Hello Power Platform Community,
I am currently working on implementing pagination in a gallery using Power Apps, but I am encountering an issue when I try to display data in pages. I am using the following formula on Items Property of Gallery:
Whenever I try to use this formula, I get an error message: "We didn't find any data." The data source appears to be correct, and I have set up the context variables on "OnVisible" property of Screen
but I still cannot display the data as expected.
varRowsPerPage
and varPage
).varRowsPerPage
and varPage
are correctly initialized and updated.Any help or suggestions would be greatly appreciated!
This type of post provides context for your error, details about what you’ve tried so far, and specific questions that can guide others in the community to help you troubleshoot.
LastN(
FirstN(
Filter(
'Purchase Requisition',
Len(txtInput_Search_2.Value) = 0 ||
txtInput_Search_2.Value in Text(ID) ||
txtInput_Search_2.Value in 'Date of Requisition' ||
txtInput_Search_2.Value in 'Requisitioned by'.DisplayName ||
txtInput_Search_2.Value in Location.Value ||
txtInput_Search_2.Value in Department.Value ||
txtInput_Search_2.Value in 'Requisitioned by'.DisplayName ||
txtInput_Search_2.Value in Status.Value ||
txtInput_Search_2.Value in 'Approved by'.DisplayName
),
varRowsPerPage * varPage
),
varRowsPerPage
)
Filter( 'Purchase Requisition', ( ( CheckboxApproved.Checked && Status.Value = "Approved" ) || ( CheckboxPending_1.Checked && Status.Value = "Pending" ) || ( CheckboxRejected_2.Checked && Status.Value = "Rejected" ) || ( !CheckboxApproved.Checked && !CheckboxPending_1.Checked && !CheckboxRejected_2.Checked ) ) && ( IsBlank(varStatusFilter) || Status.Value = varStatusFilter ) && ( IsBlank(DatePickerCanvas1_1.SelectedDate) || 'Date of Requisition' >= DatePickerCanvas1_1.SelectedDate ) && ( IsBlank(DatePickerCanvas2_2.SelectedDate) || 'Date of Requisition' <= DatePickerCanvas2_2.SelectedDate) && ( IsBlank(txtInput_MinPrice.Value) || 'Price' >= Value(txtInput_MinPrice.Value) ) && ( IsBlank(txtInput_MaxPrice.Value) || 'Price' <= Value(txtInput_MaxPrice.Value) ) )
​​​​​​​
LastN(
FirstN(
'Purchase Requisition',
varRowsPerPage * varPage
),
varRowsPerPage
)
With(
{
_Data:
Filter(
'Purchase Requisition',
(
(
CheckboxApproved.Checked &&
Status.Value = "Approved"
) ||
(
CheckboxPending_1.Checked &&
Status.Value = "Pending"
) ||
(
CheckboxRejected_2.Checked &&
Status.Value = "Rejected"
) ||
(
!CheckboxApproved.Checked &&
!CheckboxPending_1.Checked &&
!CheckboxRejected_2.Checked
)
) &&
(
IsBlank(varStatusFilter) ||
Status.Value = varStatusFilter
) &&
(
IsBlank(DatePickerCanvas1_1.SelectedDate) ||
'Date of Requisition' >= DatePickerCanvas1_1.SelectedDate
) &&
(
IsBlank(DatePickerCanvas2_2.SelectedDate) ||
'Date of Requisition' <= DatePickerCanvas2_2.SelectedDate) &&
(
IsBlank(txtInput_MinPrice.Value) ||
'Price' >= Value(txtInput_MinPrice.Value)
) &&
(
IsBlank(txtInput_MaxPrice.Value) ||
'Price' <= Value(txtInput_MaxPrice.Value)
)
)
},
LastN(
FirstN(
Filter(
_Data,
Len(txtInput_Search_2.Value) = 0 ||
txtInput_Search_2.Value in Text(ID) ||
txtInput_Search_2.Value in 'Date of Requisition' ||
txtInput_Search_2.Value in 'Requisitioned by'.DisplayName ||
txtInput_Search_2.Value in Location.Value ||
txtInput_Search_2.Value in Department.Value ||
txtInput_Search_2.Value in 'Requisitioned by'.DisplayName ||
txtInput_Search_2.Value in Status.Value ||
txtInput_Search_2.Value in 'Approved by'.DisplayName
),
varRowsPerPage * varPage
),
varRowsPerPage
)
)
WarrenBelz
791
Most Valuable Professional
MS.Ragavendar
410
mmbr1606
275
Super User 2025 Season 1