Using F8 to step through all of the code, it gets to this sub, highlites Dim fs ...Code:'global declaration Dim FILE_NAME As String = "EventList.txt" Dim PATH_FILE As String = Environment.CurrentDirectory() & "\" & FILE_NAME 'end of global declaration Private Sub ProcessFiles() Dim fs As New FileStream(PATH_FILE, FileMode.Open, FileAccess.Read) Dim sr As New StreamReader(fs) Dim TextLine As String 'line from file MsgBox(PATH_FILE) Do Until sr.EndOfStream() TextLine = sr.ReadLine MsgBox(TextLine) Loop End Sub
and then hit F8 again it just pops up the form, no message boxes - nothing. Other notes: EventList does exist in stated directory.
Any ideas why it wouldn't complete the sub?
the first debug line after hit the f8 is:
A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll
...but the file is there! all 14kb of it.




Reply With Quote
