QueryResponse<T>.CurrentPage Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The current page of queried items.
public System.Collections.Generic.IEnumerable<T> CurrentPage { get; }
member this.CurrentPage : seq<'T>
Public ReadOnly Property CurrentPage As IEnumerable(Of T)
Property Value
Examples
QueryResponse<Twin> queriedTwins = await iotHubServiceClient.Query.CreateAsync<Twin>("SELECT * FROM devices");
while (await queriedTwins.MoveNextAsync())
{
Twin queriedTwin = queriedTwins.Current;
Console.WriteLine(queriedTwin);
}
Remarks
While you can iterate over the queried page of items using this, there is no logic built into it that allows you to fetch the next page of results automatically. Because of that, most users are better off following the sample code that iterates item by item rather than page by page.
Applies to
Azure SDK for .NET
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for