srgoodall
Electrical
- Feb 8, 2008
- 4
I am trying to write vb code to automatically name a txt file I wish to save in a sequential file based upon the current month. For example, in the stmt
Open "c:\Month.txt" for Output as #1
I would like to have "Month" in "Month.txt" be a variable that can be assigned with a stmt like
Month = Format(Date, "mmmm").
Problem is, in the Open stmt above, the word Month is taken as a literal name.
I suspect there is a way to do this, but I'm just learning vb.
Thanks very much.
Open "c:\Month.txt" for Output as #1
I would like to have "Month" in "Month.txt" be a variable that can be assigned with a stmt like
Month = Format(Date, "mmmm").
Problem is, in the Open stmt above, the word Month is taken as a literal name.
I suspect there is a way to do this, but I'm just learning vb.
Thanks very much.