local procedure TestNumberSequenceRange()
var
ListOfText: List of [Text];
StartDateTime: DateTime;
StartNumber: Integer;
i: Integer;
begin
StartDateTime := CurrentDateTime();
StartNumber := NumberSequence.Range(NumberSequenceLbl, NumberOfIterations, true);
for i := StartNumber to StartNumber + NumberOfIterations do
ListOfText.Add(Format(i));
Message('Number sequence range: %1 iterations took %2.', NumberOfIterations, CurrentDateTime() - StartDateTime);
end;
local procedure TestNoSeriesNoGaps()
var
NoSeriesBatch: Codeunit "No. Series - Batch";
ListOfText: List of [Text];
StartDateTime: DateTime;
i: Integer;
begin
StartDateTime := CurrentDateTime();
for i := 1 to NumberOfIterations do
ListOfText.Add(NoSeriesBatch.GetNextNo(NoSeriesCodeNoGapsLbl));
NoSeriesBatch.SaveState();
Message('Number series with no gaps: %1 iterations took %2.', NumberOfIterations, CurrentDateTime() - StartDateTime);
end;