Link to home
Create AccountLog in
Avatar of ecohouse
ecohouse

asked on

Visual Basic - ISAM Problem

I'm trying to open a VB project and I get an error message stating the following: "Couldn't Find Installable ISAM".

I'm also tried creating a test project with one form and the data control from the toolbar on the form.  And then setting up the form to use Jet, database type (Access 2000) and the database name.

When I use the pull down list for the Connect Property I only get Access instead of Access 2000.  

I'm running windows xp with Office 2000 and Office 2002 on my machine.  And I have access 97, 2000 and 2002 running also.

Any idea what I have to do to get VB working?
ASKER CERTIFIED SOLUTION
Avatar of Brian Mulder
Brian Mulder
Flag of Netherlands image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of ecohouse
ecohouse

ASKER

Thanks for the help.  I upgraded to Service Pack 6 and that helped.

The problem is in an API function and I don't know anything about them.  Do you have any API experience?
just post the function do you need a replacement?
Here's the function:

Global MyDb As Database

'multi user variables
Global gnMURetryCnt     As Integer
Global gnMUDelay        As Integer
Global gnMULocking      As Integer  'flag for pessimistic or optimistic locking

Global AgencyUpdate As Boolean
Global DBPath As String
Global InvoiceType As String

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 lpAppName$, ByVal lpKeyName As Any, ByVal lpString As Any, ByVal lpFileName$) As Long

Public Function GetIniValue(ByVal Section As String, _
                            ByVal Key As String, _
                            ByVal Default As String, _
                            ByVal File As String) As String
    Dim X As Integer
    Dim Buff As String

    On Error GoTo ERRHANDLE
   
    Buff = Space(1024)
    X = GetPrivateProfileString(Section, Key, Default, Buff, Len(Buff), File)
    GetIniValue = Left(Buff, X)
    Exit Function

ERRHANDLE:
    MsgBox "Error in GetIniValue " & Str$(Err) & ": " & Error(Err), vbInformation, "F.I.T.S."

End Function

Public Sub WriteIniValue(ByVal Section As String, ByVal Key As String, ByVal Value As String, ByVal FileName As String)
Dim X As Integer

On Error GoTo ERRHANDLE:

X = WritePrivateProfileString(Section, Key, Value, FileName)
Exit Sub

ERRHANDLE:
    MsgBox "Error in WriteIniValue " & Str$(Err) & ": " & Error(Err), vbInformation, "F.I.T.S."

End Sub

It get fired from the main form loading.  Here is that code:

Private Sub Form_Load()
   
    On Error GoTo ERRHANDLE
    'App.Path & "\" &
    DBPath = App.Path & "\" & "limodata.mdb"
   
    'DBPath = GetIniValue("Values", "DBPath", "", App.Path & "\limo.ini")
    InvoiceType = GetIniValue("Values", "InvoiceType", "", App.Path & "\limo.ini")
   
    Set MyDb = OpenDatabase(DBPath)
    Exit Sub

ERRHANDLE:
    MsgBox "Error in Main.Form_Load " & Str$(Err) & ": " & Error(Err), vbInformation, "F.I.T.S."
   
End Sub

Any help would be appreciated.