multi-instance for search by sdk
multi-instance for search by sdk
I startup a named instance,and how to use sdk to search by specified instance?
Re: multi-instance for search by sdk
The SDK does not support named instances, yet.
For now, you will need to re-build the SDK with your custom instance name.
You'll need to change the following line (there are 5 of them - change all of them):
to:
everything_hwnd = FindWindow("EVERYTHING_(instance name)",0);
where instance name is your custom instance name.
Check the ES source code.
ES uses the Everything IPC (which is what the Everything SDK is built on) and supports named instances with the -instance command line option.
For now, you will need to re-build the SDK with your custom instance name.
You'll need to change the following line (there are 5 of them - change all of them):
Code: Select all
everything_hwnd = FindWindow(EVERYTHING_IPC_WNDCLASS,0);
everything_hwnd = FindWindow("EVERYTHING_(instance name)",0);
Code: Select all
everything_hwnd = FindWindow("EVERYTHING_TASKBAR_NOTIFICATION_(instance name)",0);
Check the ES source code.
ES uses the Everything IPC (which is what the Everything SDK is built on) and supports named instances with the -instance command line option.
Re: multi-instance for search by sdk
My instance name is "abc",I try to change macro "EVERYTHING_IPC_WNDCLASS" like
#define EVERYTHING_IPC_WNDCLASSW L"EVERYTHING_(abc)"//L"EVERYTHING_TASKBAR_NOTIFICATION"
#define EVERYTHING_IPC_WNDCLASSA EVERYTHING_(abc)"//"EVERYTHING_TASKBAR_NOTIFICATION"
but search failed
#define EVERYTHING_IPC_WNDCLASSW L"EVERYTHING_(abc)"//L"EVERYTHING_TASKBAR_NOTIFICATION"
#define EVERYTHING_IPC_WNDCLASSA EVERYTHING_(abc)"//"EVERYTHING_TASKBAR_NOTIFICATION"
but search failed
Re: multi-instance for search by sdk
I changed the following line :void wrote: ↑Fri Aug 09, 2019 2:51 am The SDK does not support named instances, yet.
For now, you will need to re-build the SDK with your custom instance name.
You'll need to change the following line (there are 5 of them - change all of them):to:Code: Select all
everything_hwnd = FindWindow(EVERYTHING_IPC_WNDCLASS,0);
where instance name is your custom instance name.Code: Select all
everything_hwnd = FindWindow("EVERYTHING_(instance name)",0);
Check the ES source code.
ES uses the Everything IPC (which is what the Everything SDK is built on) and supports named instances with the -instance command line option.
Code: Select all
everything_hwnd = FindWindow(EVERYTHING_IPC_WNDCLASS,0);
Code: Select all
everything_hwnd = FindWindow("EVERYTHING_TASKBAR_NOTIFICATION_(instance name)",0);
Code: Select all
everything_hwnd = FindWindow("EVERYTHING_(instance name)",0);
I noticed ES did the same.
Code: Select all
HWND es_find_ipc_window(void)
{
wchar_t window_class[ES_BUF_SIZE];
HWND hwnd;
*window_class = 0;
es_wstring_cat(window_class,EVERYTHING_IPC_WNDCLASS);
if (*es_instance)
{
es_wstring_cat(window_class,L"_(");
es_wstring_cat(window_class,es_instance);
es_wstring_cat(window_class,L")");
}
hwnd = FindWindow(window_class,0);
return hwnd;
}
Re: multi-instance for search by sdk
Correct, does this work for you?everything_hwnd = FindWindow("EVERYTHING_TASKBAR_NOTIFICATION_(instance name)",0);