#N88BASIC
Declare Function GetPrivateProfileInt Lib "kernel32" Alias "GetPrivateProfileIntA" _
( lpApplicationName As BytePtr, _
lpKeyName As BytePtr, _
nDefault As Long, _
lpFileName As BytePtr) As Long

Declare Function GetPrivateProfileString Lib "kernel32" Alias "GetPrivateProfileStringA" _
( lpApplicationName As BytePtr, _
lpKeyName As VoidPtr, _
lpDefault As BytePtr, _
lpReturnedString As BytePtr, _
nSize As Long, _
lpFileName As BytePtr) As Long

Declare Function WritePrivateProfileString Lib "kernel32" Alias "WritePrivateProfileStringA" _
( lpApplicationName As BytePtr, _
lpKeyName As VoidPtr, _
lpString As VoidPtr, _
lpFileName As BytePtr) As Long

'ファイル名だけだとWINDOUSフォルダにつくってしまう
Const IniFile = ".\平井公彦.ini"

Dim s[20] As Byte
Dim d As Long
WritePrivateProfileString("kuki-yuuki-aki", "Kimihiko", "( ̄ー+ ̄)キラリ", IniFile)

'Iniファイルは文字列にしないとカキコできない!
d=090-7777-7777
wsprintf(s, "%d", d)
WritePrivateProfileString("kuki-yuuki-aki", "Kimihiko2", s, IniFile)

GetPrivateProfileString("kuki-yuuki-aki", "Kimihiko", "?",s,20,IniFile)
Print MakeStr(s)
d = GetPrivateProfileInt("kuki-yuuki-aki", "Kimihiko2", 64,IniFile)
Print d