I have a legacy custom application written in VB that uses an ODBC connection to an Oracle dbs. The dbs is set in an .ini file, but I'm learning that the app doesn't always check the .ini file. There is a custom function in the app as follows, and I think this is storing the dbs string somewhere.
Declare Function GetPrivateProfileString Lib "kernel32" Alias _
(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
Declare Function WritePrivateProfileString Lib "kernel32" Alias "WritePrivateProfileStringA" (ByVal lpApplicationName As String, ByVal lpKeyName As Any, ByVal lpString As Any, ByVal lpFileName As String) As Long
My problem is that the application is set up using the dev dbs. I'm trying to switch to the test environment, and I've updated my .ini file, but it's not even checking it. I can rename the file and nothing happens. If I could determine where this private profile string is stored and reset that, maybe I can get it to check the .ini file again. Can anyone please help me understand more about the kernel32 library and custom functions using it?