DECLARE FUNCTION GetIniPaht AS STRING
DECLARE FUNCTION GetIni(szSection AS STRING, svVariant AS STRING, Default AS STRING) AS STRING
DECLARE SUB WriteIni(szSection AS STRING, svVariant AS STRING, svValue AS STRING)
DIM iLenght AS INTEGER
DIM lpBuffer AS STRING
DIM uSize AS LONG
DIM svReturn AS STRING
uSize = 260
FUNCTION GetIniPaht
lpBuffer = SPACE$(uSize)
iLenght = GetWindowsDirectory( VARPTR(lpBuffer), uSize)
GetIniPaht = LEFT$(lpBuffer, iLenght)
END FUNCTION
FUNCTION GetIni(szSection AS STRING, svVariant AS STRING, Default AS STRING) AS STRING
lpBuffer = SPACE$(uSize)
iLenght = GetPrivateProfileString(szSection, svVariant, Default, @lpBuffer, uSize, szFile)
GetIni = LEFT$(lpBuffer, ilenght)
END FUNCTION
SUB WriteIni(szSection AS STRING, svVariant AS STRING, svValue AS STRING)
WritePrivateProfileString szSection, svVariant, svValue, szFile
END SUB
|