Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP staying on top
Message
 
 
À
03/02/2003 13:50:51
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00748509
Message ID:
00749062
Vues:
20
Karen,
If you can get the hWnd of the desired window you can use the Win32 API function SetForegroundWindow(Hwnd).

I use this function from a FLL that contains a variety of functions the code I use looks like this:

void FAR Activate_Window(ParamBlk FAR *parm)
{
HWND dwnd;
//DWORD thrid, tmpid;


dwnd = (HWND)parm->p[0].val.ev_long;

if (dwnd)
{
if(SetForegroundWindow(dwnd))
_RetInt(1,10);
else
_RetInt(-1,10);
}
else
_RetInt(0,10);

}

Hope This Helps,
ED

PS. If you need to find the hWnd try the Win32 API function FindWindowEx
Ed Aguinaga
ARIS, Inc
ed@arismls.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform