Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
API Call Not Working
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
API Call Not Working
Divers
Thread ID:
00672210
Message ID:
00672210
Vues:
42
This function returns empty on Win98 PC's. Works fine on
Win2000.
DECLARE INTEGER GetPrivateProfileString IN kernel32; 
  STRING   @sAppName,; 
  STRING   @sKeyName,; 
  STRING   @sDefault,; 
  STRING   @sReturn,; 
  INTEGER  @nSize,; 
  STRING   @sFileName 

sFileName = LOWER(GETFILE())
sSection  = "Application"
sKeyName  = "Top"
sDefault  = "(#default#)"	&& Return "(#default#)" if value is not found
iSize	  = 255			&& Size of the string
sReturn	  = SPACE(iSize)	&& String to contain the returned value

lRetVal = GetPrivateProfileString(@sSection, @sKeyName, @sDefault,;
		@sReturn, @iSize, @sFileName)

sReturn = STRTRAN(sReturn, CHR(0), "")

MESSAGEBOX(TRANSFORM(lRetVal))
MESSAGEBOX(sReturn)

RETURN
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform