sferguson
11-14-2003, 10:24 PM
alright, i've been fighting with this thing for a while now, see if anyone knows the correct APM5 method for getting this done. trying to find the window "Reporter Base 7 - BI" -- I put in a dialog to alert when the window is found, which it has been. i run into problems when i try to bring it to the front. i have included the code i am running, any help is much appreciated. (ps. this is just the current window.show iteration i tried, i've been through a couple of possibilities.)
--
tabCurWins = Window.EnumerateProcesses();
iLoop = 1;
iMax = Table.Count(tabCurWins);
bWinFound = false;
while (iLoop < iMax) do
if (tabCurWins[iLoop]) == "Reporter Base 7 - BI" then
iLoop = iLoop + 1;
else
bWinFound = true;
result = Dialog.Message("Notice", "Found it!", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
Window.Show(iLoop.GetWndHandle());
iLoop = 100;
end
end
--
tabCurWins = Window.EnumerateProcesses();
iLoop = 1;
iMax = Table.Count(tabCurWins);
bWinFound = false;
while (iLoop < iMax) do
if (tabCurWins[iLoop]) == "Reporter Base 7 - BI" then
iLoop = iLoop + 1;
else
bWinFound = true;
result = Dialog.Message("Notice", "Found it!", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
Window.Show(iLoop.GetWndHandle());
iLoop = 100;
end
end