Close
dtSearch Engine API for .NET Framework 2.x-4.x 2024.01
SearchResults Class

List of documents retrieved in a search.

dtSearch::Engine::DisposableObject | dtSearch::Engine::SearchResults
public class SearchResults : DisposableObject;

After a search, SearchJob.Results will contain a SearchResults listing the documents found in the search. 

To access information about each document, call GetNthDoc() to select the document in the list, then use CurrentItem to access its properties.

IDisposable

When using the dtSearch Engine API, it is essential to use the IDisposable pattern with all API objects except JobErrorInfo. Otherwise, the .NET garbage collector may take a long time to free memory used by potentially large objects such as SearchResults, resulting in memory depletion in long-running applications. In C# code, use a "using" clause with dtSearch Engine API objects, and in other code call Dispose() when you are done with an object.