Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Form losing focus
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Divers
Thread ID:
00962204
Message ID:
00962449
Vues:
7
>I have a Form. In this Form I instantiate a COM component. This component has a Create_Object method to create business and return objects within this component.
>
>
>loCOM = CreateObject("Server.Class")
>loCOM.Create_Object("BusinessAsUsual")
>
>
>As soon as I use this method my form loses its focus and it doesn't return. If I press Alt-TAB I can see a Windows logo with the name of the Component. If I select that nothing happens but pressing Alt-TAB again doesn't show this component again. Using Alt-Tab I can get focus back on my application (and the form). How can I prevent this form losing its focus or how do I reset it after it is lost?

If this is VFP 7.0 or later, you could use the API command SetActiveWindow() in the API in the Show event.
George

Ubi caritas et amor, deus ibi est
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform