ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Can you manipulate text documents using VBA in excel (https://www.excelbanter.com/excel-programming/298548-can-you-manipulate-text-documents-using-vba-excel.html)

Sladey

Can you manipulate text documents using VBA in excel
 
I'm tring to add a bit of code to my VBA in excel that will:

Save a text file in a directory as a new file in another directory.

Many Thanks

--
Message posted from http://www.ExcelForum.com


Stephan Kassanke

Can you manipulate text documents using VBA in excel
 

"Sladey " schrieb im Newsbeitrag
...
I'm tring to add a bit of code to my VBA in excel that will:

Save a text file in a directory as a new file in another directory.

Many Thanks.


---
Message posted from http://www.ExcelForum.com/


Hi Sladey,

in other words: you want to copy a file from one directory to another? If
so:

FileCopy source, destination

is your friend. You can provide a fully classified file name for the
arguments.

FileCopy "c:\temp\myfile.txt", "c:\newdir\myfile.txt"

cheers,

Stephan






All times are GMT +1. The time now is 12:30 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com