Created
April 12, 2016 19:39
-
-
Save henzard/429c67ab9dabec49a96b99cf91c3d145 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
List<Invoice> AllInvoices = new List<Invoice>(); | |
List<Invoice> CurrentInvoices = new List<Invoice>(); | |
int i = 1; | |
CurrentInvoices = _api.Invoices.Page(i).Find().OrderBy(e => e.DueDate).ToList(); | |
while(CurrentInvoices != null) | |
{ | |
AllInvoices.AddRange(CurrentInvoices); | |
i++; | |
CurrentInvoices = _api.Invoices.Page(i).Find().OrderBy(e => e.DueDate).ToList(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment