Cheers for this, I have tried to do the Input # Statement listed in the first link you gave me. I pasted the code into an excel macro and then ran the macro and no error messages appeared but the data in the text file did not appear in the workbook. all i had in the text file was the number 65.
was this because i didnt specify which cell the data should be entered into? I don't understand this very well as I am new to visual basic but i really need to work out how to do this!
this is the code i put into the macro, am i missing some things?
Thank you very much for the link and help by the way, this is the closest i have got to working it out so far, unfortunately i lack the knowledge of the programme to fill in any gaps whatsoever so it might seem like im asking silly questions!
cheers!
Code:
Sub FIR()
Dim MyString, MyNumber
Open "C:\Users\Ben\Documents\test.txt" For Input As #1 ' Open file for input.
Do While Not EOF(1) ' Loop until end of file.
Input #1, MyString, MyNumber ' Read data into two variables.
Debug.Print MyString, MyNumber ' Print data to the Immediate window.
Loop
Close #1 ' Close file
End Sub