open a file

J

jeff

Hi,

If all you want to do is read "readme.txt"
try having your command button call this:

Sub OpenMyFile()
Open "C:\Readme.txt" For Input As #1
Line Input #1, A$
MsgBox "You read in " & A$
Close #1
End Sub

jeff
-----Original Message-----
as silly as this may seem...

all i want to do is open a text file, linked to
commandbutton1, stored in S:\readme.txt
 
C

camron107

cheerz for your help but none of these work!

I get the runtime error '52'

Bad filename or number....

and it highlights the Line "Line Input #0, A$" in yellow.

I dont understand why nor do i understand the syntax, do i need to manipulate it?

thanx again
 
Top