Search results are incremented

Hi Bart,

I'm using the code below to go through the search results from Google Drive, using an exact match for a filename within a given folder, so I'm always expecting to get a single item returned.

procedure TForm1.TMSFNCCloudStorageServices1Search(Sender: TObject;
const ASearchResults: TTMSFNCCloudItems;
const ARequestResult: TTMSFNCCloudBaseRequestResult);
var
I: Integer;
fname: string;
ci: TTMSFNCCloudItem;
begin
if not Assigned(ASearchResults) then
Exit;

showmessage( 'Number of search results found is ' + ASearchResults.Count.ToString ) ;

for I := 0 to ASearchResults.Count - 1 do
begin
ci := ASearchResults.Items[I];
fname := ci.FileName ;
showmessage('File: ' + fname ) ;
end;
end;

This all works just fine, for the first query which returns the singular result expected.

The second query returns 2 items (the second result and also the first one) the third query returns 3 items (the third after the first 2, etc).

Is this behaviour as expected? Do I have to clear down the SearchResults somehow after I've read them?

Sorry for all the questions, it's been an interesting afternoon.

Best regards,

Adam