View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
spence[_2_] spence[_2_] is offline
external usenet poster
 
Posts: 8
Default create .TXT file Log

i have this to create a txt file in excel's program files
directory. how can i modify it to put the txt file on my
C:\ drive.


Private Sub workbook_beforeclose(cancel As Boolean)
Open Application.Path & "\Log.txt" _
For Append As #1
Print #1, "Stopped " & Now
Close #1
End Sub

TIA