rendered paste bodyDWORD WINAPI ArcGISEngineRuntime_Thread()
{
bArcGISEngineRuntime_Success = false;
bool once = false;
while (1)
{
while (FindWindow(NULL,"ArcGIS Engine Runtime Setup") == NULL) Sleep(0);
while (HWND wndParent = FindWindow(NULL,"ArcGIS Engine Runtime Setup"))
{
wndParent = FindWindow(NULL,"ArcGIS Engine Runtime Setup");
if (HWND wndBtn = FindWindowEx(wndParent,NULL,"Button","&Next >"))
SendMessage(wndParent,WM_COMMAND,MAKELONG(GetDlgCtrlID(wndBtn),BN_CLICKED),(LPARAM)wndBtn);
if (!once && FindWindowEx(wndParent,NULL,NULL,"Updating System"))
{
AddLog("Waiting for %s Setup to finish.",CurrentSetup);
once = true;
}
if (HWND wndBtn = FindWindowEx(wndParent,NULL,"Button","&Finish"))
{
SendMessage(wndParent,WM_COMMAND,MAKELONG(GetDlgCtrlID(wndBtn),BN_CLICKED),(LPARAM)wndBtn);
bArcGISEngineRuntime_Success = true;
TerminateThread(hArcGISEngineRuntime,0);
}
}
Sleep(0);
}
retu