-----Original Message-----
Hi Rob,
This code will open a file, grab the value in the file, store it in a
variable, increment it by one, and save it back to the file.
Sub ReadWriteTextFromFile()
Dim FileNumber As String
Dim strCount As String
Const cFile = "C:\Test\TextFile.txt"
'Read from file
FileNumber = FreeFile()
Open cFile For Input As #FileNumber
Input #FileNumber, strCount 'this puts the value found in the text file into
the variable strCount
Close #FileNumber ' Close file.
strCount = CStr(CInt(strCount) + 1) 'increment the counter
'Replace the file with the new value
Kill cFile
'create new file with new value
FileNumber = FreeFile()
Open cFile For Append As #FileNumber
Print #FileNumber, strCount 'write the new value to the file
Close #FileNumber ' Close file.
End Sub
Steve, i'm sorry... i am Excel illiterate!! What i need