VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

EZ .ini

Frank Joseph Mattia  (1 Submission)   Windows API Call/Explanation   Visual Basic 3.0   Unknown Difficulty   Wed 3rd February 2021

Access .ini files in the blink of an eye. Use one line of your input to quickly retrive .ini values. With the same one line of code write to your .ini file. If you have any improvements on this code, E-Mail me at "[email protected]".

Assumes
When you call this in your code, this is the syntax you will need to use. Dim X As String X = mfncGetFromIni(SectionHeader, VariableName, FileName) Text1.Text = X

Returns
Returns the value of a string of an .ini file.

Side Effects
None.

API Declarations
Public Declare Function GetPrivateProfileString Lib "kernel32" 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
Public 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

Rate EZ .ini (39(39 Vote))
EZ .ini.bas

EZ .ini Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters