Well - I've been playing with ini files for awhile... what I'm working on now is a program settings form which is SUPPOSED to let the user make changes to the main GUI.
I'm making use of the WritePrivateProfileString function built into the API.
-******Snip of Function*******_
Function putIniVal(ByVal strHeader As String, ByVal strKey As String, Value, ByVal strFilename As String) As Integer
'Write the value to the ini file.
lngReturnValue = WritePrivateProfileString(strHeader, strKey, Value, strFilename)
-******ENDOF Snip of Function*******_
The putIniVal function *works* in that it does modify the ini file correctly. The problem I am having is that if I read the ini file right after I write to it, the changes are not reflected. If I close the program, restart the program the changes appear.
so if I do
I don't get 255 I get the old value...
In my reading I found that win.ini is cached - are all ini's cached?
More importantly - what can I do to ensure that the putIniVal function makes the changes to the ini file immediately???