Hi
I need to read/write a file which I can access with idexes.
Using a database isn't required as it would be just a few settings.
Could you suggest me a method for this?
Thanks in advance,
Malinda
Index based read/write in VB
Re: Index based read/write in VB
Use following API to read/write settings to and from INI files
Code: Select all
Private Declare Function GetPrivateProfileString Lib "kernel32.dll" Alias "GetPrivateProfileStringA" (ByVal lpApplicationName As String, ByVal lpKeyName As Any, ByVal lpDefault As String, ByVal lpReturnedString As String, ByVal nSize As Long, ByVal lpFileName As String) As Long
Private Declare Function WritePrivateProfileString Lib "kernel32.dll" Alias "WritePrivateProfileStringA" (ByVal lpApplicationName As String, ByVal lpKeyName As Any, ByVal lpString As Any, ByVal lpFileName As String) As Long