cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Daemagor
Level: Powered On

Pagination with 500+ records in sharepoint list

My ticket system just reached 500+ records in the sharepoint list. From what I understand, powerapps will only show the 1st 500 records in the list. I have filters on the item in the gallery and it still isnt showing tickets over 500. I have read up on Pagination, but I would like it to do pagination once it has reached the bottom of the list.

EX: I get the 1st batch of 500 records, I scroll all the way to the bottom of the list and i will get the next 500 records.

 

From what I saw from this post on Powerusers, he has done it with buttons. Here is my code that I have, I have no idea how to implement this without breaking my app. Help Please.

 

If(AdminAccess = true,
	If(IsBlank(TextSearchBar.Text), 					
		SortByColumns(
			If(TicketView = "All", 
				Tickets_1, 
				
				If(TicketView = "Completed" || TicketView = "In Progress" || TicketView = "None Selected" || TicketView = "Waiting on Submitter" || TicketView = "Waiting on Shipment" || TicketView = "Waiting on 3rd Party Support" || "Waiting" in TicketView || 
				TicketView = "IT Testing" || TicketView = "End User Testing" || "Testing" in TicketView ,
					Filter(Tickets_1,TicketView in Status.Value),
					
					If(TicketView = "High" || TicketView = "Medium" || TicketView = "Low" || TicketView = "Critical", 
						Filter(Tickets_1,New_Priority.Value=TicketView && Status.Value <> "Completed"),
						
						
						If(TicketView = "Assigned", 
							Filter(Tickets_1,Worker.DisplayName=UserLoggedIn.Text && Status.Value <> "Completed"),
						
							If(TicketView = "(Team)" || TicketView = "(Team)" || TicketView = "(Team) " || TicketView = "(Team) " || TicketView = "(Team)", 
								Filter(Tickets_1,Group.Value=TicketView && Status.Value <> "Completed"),
								
								Filter(Tickets_1, Status.Value=TicketView)))))),
			"ID", If(SortDescending1, 
				Ascending, 
				Descending)
		),
		If(IsNumeric(Value(TextSearchBar.Text)),
			SortByColumns(Filter(Tickets_1, ID = Value(TextSearchBar.Text)), "ID", If(SortDescending1, Ascending, Descending)),
			
			If(TicketView = "All",
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName)), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Completed"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "Completed")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Open"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "Open")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "In Progress"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "In Progress")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "None Selected"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "None Selected")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Waiting on Submitter"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "Waiting on Submitter")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Waiting on Shipment"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "Waiting on Shipment")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Waiting on 3rd Party Support"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "Waiting on 3rd Party Support")), "ID", If(SortDescending1, Ascending, Descending)),
			("Waiting" in TicketView),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (TicketView in Status.Value)), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "IT Testing"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "IT Testing")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "End User Testing"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (Status.Value = "End User Testing")), "ID", If(SortDescending1, Ascending, Descending)),
			("Testing" in TicketView),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (TicketView in Status.Value)), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "High" || TicketView = "Medium" || TicketView = "Low" || TicketView = "Critical"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (TicketView = New_Priority.Value) && (Status.Value <> "Completed")), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "Assigned"),
				SortByColumns(Filter(Tickets_1,Worker.DisplayName=UserLoggedIn.Text && Status.Value <> "Completed"), "ID", If(SortDescending1, Ascending, Descending)),
			(TicketView = "(Team) " || TicketView = "(Team) " || TicketView = "(Team) " || TicketView = "(Team) " || TicketView = "(Team)"),
				SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName) && (TicketView = Group.Value) && (Status.Value <> "Completed")), "ID", If(SortDescending1, Ascending, Descending)),
			SortByColumns(Filter(Tickets_1, (TextSearchBar.Text in Name.DisplayName || TextSearchBar.Text in Title || TextSearchBar.Text in Worker.DisplayName)), "ID", If(SortDescending1, Ascending, Descending))
			)
		)
	),
	If(IsBlank(TextSearchBar.Text),
		SortByColumns(
			If(TicketView = "All", 
				Filter(Tickets_1, Name.DisplayName = UserLoggedIn.Text), 
				
				If(TicketView = "Completed" || TicketView = "In Progress" || TicketView = "None Selected" || TicketView = "Waiting on Submitter" || TicketView = "Waiting on Shipment" || TicketView = "Waiting on 3rd Party Support" || "Waiting" in TicketView || 
				TicketView = "IT Testing" || TicketView = "End User Testing" || "Testing" in TicketView,
					Filter(Tickets_1,TicketView in Status.Value && Name.DisplayName = UserLoggedIn.Text),
					
					If(TicketView = "High" || TicketView = "Medium" || TicketView = "Low" || TicketView = "Critical", 
						Filter(Tickets_1,New_Priority.Value=TicketView && Status.Value <> "Completed" && Name.DisplayName = UserLoggedIn.Text),
										
					Filter(Tickets_1, Status.Value=TicketView && Name.DisplayName = UserLoggedIn.Text)))),
			"ID", If(SortDescending1, 
				Ascending, 
				Descending)
		),
		If(IsNumeric(Value(TextSearchBar.Text)),
			SortByColumns(Filter(Tickets_1, ID = Value(TextSearchBar.Text), User().FullName = Name.DisplayName), "ID", If(SortDescending1, Ascending, Descending)),
			SortByColumns(Filter(Tickets_1, StartsWith(Name.DisplayName, TextSearchBar.Text), User().FullName = Name.DisplayName), "ID", If(SortDescending1, Ascending, Descending))
		)	
	)
)