Stop an ongoing search via SDK

Discussion related to "Everything" 1.5 Alpha.
Post Reply
err_24546
Posts: 30
Joined: Wed Oct 11, 2023 1:47 am

Stop an ongoing search via SDK

Post by err_24546 »

If I end up with a search started using the current SDK, which is taking too long, is there a way to stop the process, and only have the results obtained up to that point?
void
Developer
Posts: 15401
Joined: Fri Oct 16, 2009 11:31 pm

Re: Stop an ongoing search via SDK

Post by void »

Everything tracks IPC queries by reply window handle.

The easiest way to cancel a long search is to send another query with the same reply window handle.
The new query will cancel the old query.

To cancel a query:
Send Everything a new query with the search: nothing:
Wait for the results, they should be instant.
err_24546
Posts: 30
Joined: Wed Oct 11, 2023 1:47 am

Re: Stop an ongoing search via SDK

Post by err_24546 »

void wrote: Tue Apr 23, 2024 10:54 pm To cancel a query:
Send Everything a new query with the search: nothing:
Wait for the results, they should be instant.
Thanks, void. This also works for Everything v1.4?
void
Developer
Posts: 15401
Joined: Fri Oct 16, 2009 11:31 pm

Re: Stop an ongoing search via SDK

Post by void »

Yes.

The nothing: search function doesn't exist in Everything 1.4.
It will still match nothing.
err_24546
Posts: 30
Joined: Wed Oct 11, 2023 1:47 am

Re: Stop an ongoing search via SDK

Post by err_24546 »

Thanks void, good to know.
Kudos for your hard work and premier tech support.
Post Reply