vb
Private Sub Command1_Click()
'Get a free file number
nFileNum = FreeFile
'Open a text file for input. inputbox returns the path to read the file
Open ("C:\Program Files\Microsoft Visual Studio\VB98\bioemp\") For Random As Text1.Text
lLineCount = 1
'Read the contents of the file
Do While Not EOF(nFileNum)
Line Input #nFileNum, sNextLine
'do something with it
'add line numbers to it, in this case!
sNextLine = sNextLine & vbCrLf
sText = sText & sNextLine
Loop
Text1.Text = sText
Close nFileNum
End Sub
## Run time error 13
type mismatch
Mod Edit: Please use code tags when posting your code. Code tags are used like so =>

Thanks,
PsychoCoder