based on the key, I'm trying to pull a value out of an ini file and put it into a variable. I can't seem to find any examples that make alot of sense. any ideas?

Use the GetPrivateProfileString API call. 
(16 bit compatibility, 64kb files max) 
Example: 
http://groups.google.com/groups?hl=en&selm=E2F6A70FE45242488C865C3BC1245DA74EBEF1%40lnewton.leeds.lfs.co.uk 


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 Function GetIniSetting(IniFileName As String, _ 
                              IniSectionName As String, _ 
                              EntryName As String, _ 
                              ByRef ReturnString As String) As Integer 
                               
    Dim rtnString As String * 1024 
     
    GetIniSetting = GetPrivateProfileString(IniSectionName, _ 
                                            EntryName, _ 
                                            "", _ 
                                            rtnString, _ 
                                            Len(rtnString), _ 
                                            IniFileName) 
                                             
    If GetIniSetting <> 0 Then 
        ReturnString = Trim$(Left(rtnString, GetIniSetting)) 
    Else 
        ReturnString = "" 
    End If 

    Exit Function 
     
End Function 

Command1_Click() 
   Dim returncode as Integer 
   Dim workstring as String 
  
   returncode = GetIniSetting("C:\test.ini", _ 
                             "OPTION", _ 
                             "KEY", _ 
                             workstring) 
    If returncode <> 0 Then 
      'do some code here 
    end if 
End Sub 
