The Microsoft Jet Database Engine cannot find the input table or query 
Author Message
 The Microsoft Jet Database Engine cannot find the input table or query

What I am doing is have the user enter and date and then taking data
from a table based on that date and creating a new table with the data
taken from the first table.  After that I run a query and the newly
created table.  This works fine the first time the database is opened,
but if I try again I get this error: The Microsoft Jet Database Engine
cannot find the input table or query TimeandTravelSubmit.  Make sure
it exists and that its name is spelled correctly.    After I exit this
error message, I go an check and the newly created table named
TimeandTravelSubmit does indeed exist.  If I exit the database and go
back in everything works fine, it is only after the first time that I
get the error message.

Here is the code that is causing the problem:

Private Sub SubmitButton_Click()

    Dim SQLTraining As String
    Dim rstTraining As Recordset
    Dim dbsTimeTrav As Database
    Dim Msg, Style, Response
    DoCmd.Hourglass True
    DoCmd.TransferDatabase acExport, "Microsoft Access",
    "c:\office\timetravel\TimeTrav.mdb", acTable, "ReleaseQuery",
    "TimeandTravelSubmit", False

    Set dbsTimeTrav = CurrentDb()
    Set rstTraining = dbsTimeTrav.OpenRecordset("TrainingCheckQuery")
    If Not rstTraining.EOF Then
        rstTraining.MoveLast
    End If

    If rstTraining.RecordCount > 0 Then
        Msg = "You are submitting a timesheet that uses the training AU
        Code of 0010.  Click Yes if you want to release the timesheet
        anyway, or No to open the timesheet for correction."
        Style = vbYesNo
        Response = MsgBox(Msg, Style)
        rstTraining.Close
        If Response = vbNo Then
            DoCmd.Hourglass False
            Exit Sub
        End If
    End If
    DoCmd.TransferText acExportFixed, "TimeandTravelSubmit Export
    Specification", "TimeandTravelSubmit",
    "C:\office\timetravel\tatsub.txt", False, ""
    Beep
    MsgBox "Your timesheet has been transferred to
    C:\OFFICE\TIMETRAV\TATSUB.TXT", vbInformation, "File Transferred"
    DoCmd.Hourglass False
End Sub

Does anyone have any ideas?  The line "Set rstTraining =
dbsTimeTrav.OpenRecordset("TrainingCheckQuery")" is where the error
always happens.  I am thinking that maybe there is a way to have the
database stop and reevaluate itself after the TransferDatabase command.
Any help would be great.

Thanks,
Wendi

--
Posted via http://www.*-*-*.com/



Mon, 30 May 2005 04:17:56 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Microsoft Jet Database Engine Cannot Open The File.......(access)mdb

2. The Microsoft Jet database engine cannot......

3. The Microsoft Jet database engine cannot open the file

4. Microsoft Jet Database Engine Cannot Open The File.......(access)mdb

5. The Microsoft Jet database engine cannot open the file

6. Microsoft Jet Database Engine cannot open the file

7. Help: Cannot find input table or query (ODBC 3078)/ Unbuffered Informix 7.24

8. 3197 Microsoft Jet database engine

9. Microsoft Jet Database Engine

10. Microsoft's Jet Database Engine Book

11. Microsoft JET Database Engine (0x80004005) error

12. Microsoft JET Database Engine error '80040e09'

 

 
Powered by phpBB® Forum Software