Look for example MSN:
Caption: L"Windows Live Messenger"
part of Getting HANDLE and Process ID
hW = FindWindow(L"MSBLWindowClass",L"Windows Live Messenger");
GetWindowThreadProcessId(hW,&pID); // get the things...
int (__cdecl *pHandle)(DWORD) = (int(__cdecl*)(DWORD))hW;
int (__cdecl *pRocess)(DWORD) = (int(__cdecl*)(DWORD))pID;
// p_s is my printout function..
p_s("Handle: %p (0x%X)",pHandle,pHandle);
p_s("Process: %p (0x%X)",pRocess,pRocess);
(when you debug you'll get the results..)
Now looking with Spy++
Handle of the window: (000)10372
Process ID of the window: (thats not changing when it's active unless you restart the pgoram): (00000)E68
Thread ID of the window (what im currently looking to get (samething above 'restart cetera..')): (00000)E6C
P.S The GetCurrentThread combination of passing it to GetThreadId didn't work out
HANDLE _eng; // global
_eng = GetCurrentThread();
Hi. I have a form with list box : lst_product, datagridview : grd_order and button: btn_addline. lst_product has a list of product ids selected from database (MS Acess 2013) , grd_order is by default empty except for 2 headers and btn_addline adds rows to grd_order.
I am writing a java program that needs to execute shell commands, so I wrote a function that would take the command to execute as a string (ie: "mkdir ~/Folder1") and execute that command with the shell. Here is the function:
Runtime run = Runtime.getRuntime();
Process pr = ...
Hey, so I wanna ask how I need to create a method who will remove word if in that word is 2 same chars. Example: "Potato" in this word there is a 2 "o" chars so this word will need to be removed. "Forum" in this word there is no ...