See, I want to get some basic experience working with file I/O, so I visited this page here
https://wiki.openoffice.org/wiki/Docume ... e_Library)
which taught me the Dir function.
I have a directory "C:\stuey" with three files in it, "calcsheet", "diamond", and "asics".
I copied the function from that BASIC_Guide page I linked to above, see:
Code: Select all
Sub ShowFiles
Dim NextFile As String
Dim AllFiles As String
AllFiles = ""
NextFile = Dir("C:\", 0)
While NextFile <> ""
AllFiles = AllFiles & Chr(13) & NextFile
NextFile = Dir
Wend
MsgBox AllFiles
End Sub
Shouldn't the MsgBox instead list the three files in the C:\stuey directory?