View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Closing file with Macro

The filename in strFile in this statement:
Workbooks(strFile).Close savechanges:=false
can't include the drive and folder names--it's just the name of the file.


MC wrote:

<<Snipped

I guess you can try to close workbook named the same as opened text file,
e.g. as below:

Workbooks(strFile).Close savechanges:=false

HTH

Mariusz C
NT_SPAM


--

Dave Peterson