Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
LookupAccountName()
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00831399
Message ID:
00831440
Vues:
12
Hi Josh,

Here's a sample code. You'll have to add error checking at least.
DECLARE Long LookupAccountName IN Advapi32.DLL ;
  STRING lpSystemName, STRING lpAccountName, STRING @ Sid, Long @ cbSid, ;
  STRING @ ReferencedDomainName, Long @cchReferencedDomainName, STRING @ peUse

lcAccountName = "Josh" + CHR(0)
lcSID = REPLICATE(CHR(0), 32)
lcDomainName = REPLICATE(CHR(0), 64)
lnDNsize = LEN(lcDomainName)
lnSIDsize = LEN(lcSID)
lcpeUse = REPLICATE(CHR(0), 4)
? LookupAccountName(0, lcAccountName, @lcSID, @lnSIDsize, ;
		@lcDomainName, @lnDNsize, @lcpeUse)
>this api call retreives the user SID;
>any clue as to how to get this one to work in vfp?
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform