Edit: I've been working on an XP virtual machine (32bit) running Access 2003 when messing with this.
I'm currently working with a database that's been in use for years to upload excel data into appropriate tables in an access database. However, recently, I've started getting an "input past the end of file" error and I haven't had any luck fixing it. I'm not a coder and the person who designed this database left ages ago. I don't really have anyone I can ask, so I turn to you lovely internet people!
The bit of code that I believe is the culprit:
Code:
Private Function Get_PIDN_From_EyeTrack(FileIn As String, ByRef PIDN As Integer, ByRef TableName As String)
Dim lineX As Integer
Dim mytext As String
Dim Tab1 As Integer
Dim Tab2 As Integer
Open FileIn For Input As #1
lineX = 1
Line Input #1, garbage
Line Input #1, mytext
Tab1 = InStr(1, mytext, Chr(vbKeyTab))
Tab2 = InStr(Tab1 + 1, mytext, Chr(vbKeyTab))
PIDN = Mid(mytext, 1, Tab1 - 1)
TableName = Mid(mytext, Tab1 + 1, Tab2 - (Tab1 + 1))
Close #1
End Function
I tried adding a "Do While Not EOF(1)" before Line Input, and a "Loop" before Close #1 but got the same error. This is the only Function in all of the code that uses the word "Input".
I'm guessing that I'll likely have to post all of the code in this database, or just attach a copy of the database itself (there's no identifying information in it, and it's only about 10Mb) to make proper sense of everything...along with a sample upload file.
Side question: is "garbage" a command? Or just the guy who wrote this being lazy and defining things as "garbage"?