Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ExitWindowsEx
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
Divers
Thread ID:
00182764
Message ID:
00182828
Vues:
16
>Sorry,
> Forgot to show the statement...:(
> set library to foxtools
> #DEFINE EWX_SHUTDOWN 1
> getout=regfn("ExitWindowsEx","II","I")
> =CALLFN(getout,EWX_SHUTDOWN,0)

ExitWindowsEx sends a WM_QUERYENDSESSION message to all applications. If any of those applications return a 0 the shutdown is terminated. This happens if you answer no to the save data messagebox. Some applications will not allow themselves to be closed by ExitWindowsEx (Outlook is one). You have to close the application first.

You can add EWX_FORCE (4) to the 2nd parameter to force the shutdown to happen. However, you could potentially lose unsaved data because it does not send WM_QUERYENDSESSION or WM_ENDSESSION messages to open applications.
Steve Ruhl
CitiMortgage, Inc.
steven.ruhl@citibank.com Office
Steve@steven-ruhl.com Home
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform