Opening and closing text files
Vince,
There are 2 ways:
Use -
Application.Displayalerts = False at the beginning of the code
and
Application.Displayalerts = True at the end.
also include
Application.CutCopyMode = False
after the paste (to clear the clipboard)
steve
"Vince" wrote in message
...
I am opening a text file that is tab delimited via VBA
code. After I copy the data that I want to copy, then
select the current active worksheet and paste the data, I
close the text file. When I close the text file, I always
get the message
"There is a large amount of data on the clipboard, do you
want to save the data...yes, no, cancel".
Is there a way to close the file without having to answer
this question each time?
Any ideas would be appreciated.
Vince
|