Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Making top level form active
Message
De
31/03/2003 19:44:28
Mike Sue-Ping
Cambridge, Ontario, Canada
 
 
À
30/03/2003 20:43:58
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00768739
Message ID:
00772233
Vues:
28
Hi Dennis,

Yes, lh_form is a reference to the currently active form (in this case app_start) and has a form property, HWnd, that stores the Windows handle.

I think that this property may be new to VFP 7 (which is what I'm using) and I don't remember if previous versions of VFP had it.

Mike.

>Hi Mike,
>
>The last line in your code:
>
>
>=SetForegroundWindow(lh_form.HWnd)
>
>
>Is 'lh_form.HWnd' typed exactly as is? Since you put a dot, is HWnd a property of lh_form?
>
>Thanks
>
>My solution was to put the following before the READ EVENTS statement in my startup VFP prg:
>
>
>DO FORM app_start
>lh_form = _SCREEN.ACTIVEFORM
>DECLARE SHORT SetForegroundWindow IN USER32.DLL INTEGER hWnd
>=SetForegroundWindow(lh_form.HWnd)
>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform