Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Declare in...
Message
De
08/11/2001 10:53:52
Kenneth Downs
Secure Data Software, Inc.
New York, États-Unis
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
Declare in...
Divers
Thread ID:
00579100
Message ID:
00579100
Vues:
55
Folks,

Having trouble declaring API functions, in particular printer functions.

First, GetDefaultPrinter is supposed to have a boolean return, but DECLARE DLL does not support keywords BOOLEAN or LOGICAL. I have been using SHORT on the assumption that a C logical is actually an integer.

Second, I cannot figure how to translate MSDN's libraries into the actual "IN..." clause of the Declare DLL command. For instance, GetDefaultPrinter is supposed to be in library Winspool.lib, but:

If I try DECLARE SHORT GetDefaultPrinter In Winspool I get "Cannot open 32-bit library Winspool". Same for "...in Winspool.lib" and "...in Winspool.dll"

If I try Win32api, the declaration fails with "Cannot find entry point..."

If I try User32.dll it will accept the declaration, but fail on the call with "Cannot find entry point..."

Have been very careful about case throughout.

Any help much appreciated
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform