dtSearch.Engine.SearchJob searchJob = new dtSearch.Engine.SearchJob();
searchJob.Request = searchRequest.Text;
searchJob.IndexesToSearch.Add(indexPath.Text);
searchJob.MaxFilesToRetrieve = 100;
searchJob.SearchFlags = SearchFlags.dtsSearchDelayDocInfo;
searchJob.Execute();
if (searchJob.Errors.Count > 0)
// ... display error messages ...
else {
dtSearch.Engine.SearchResults results;
results = searchJob.Results;
// ... display search results ...
}