I need a VBA code that can do this
I want this vba code to copy all files from one specific folder to another specific folder
Thanks in advance
I need a VBA code that can do this
I want this vba code to copy all files from one specific folder to another specific folder
Thanks in advance
This is one method. The following will copy the folders and the files between folders.
Please Login or Register to view this content.
No spaces in the foldernames.
Please Login or Register to view this content.
Kind regards, Harry.
I dont want to delete the files from the source folder
Also can we delete the part about date, I have no problem with the dates.
Can we adjust the coding as such please?
Thanks
Last edited by misterno; 10-30-2022 at 01:17 PM.
At the very bottom of the FUNCTION code, eliminate these lines of code :
Please Login or Register to view this content.
You are welcome.
never mind
Last edited by misterno; 10-30-2022 at 02:28 PM.
Well ... according to your last posted example of code, you've implement the SUBS and the FUNCTION twice. Its like you pasted the code twice.
Did you mean to do that ?
Last edited by misterno; 10-30-2022 at 02:17 PM.
I tested the code here and cannot duplicate the error (.txt files) that you are seeing there.
The code is designed to copy all files without regard of the type.
???
I just tried again with a different CSV file size 126kb and it worked
But the CSV file I am trying to copy is 9K kb, is that the reason why it is not copying?
This big file has 43K lines-rows of data
Last edited by misterno; 10-30-2022 at 02:36 PM.
Logit
Would you please try your code with a large CSV file please?
And let me know
Thanks
Post the .CSV file you have that refuses to be copied. I'll use it and try to understand what is occurring.
Try again but this time delete a good portion of the data in the file. Just need maybe 200 rows of sample data.
I forget what the max limit size is for files here.
Why not just copy the folder and rename?
Good Luck
I don't presume to know what I am doing, however, just like you, I too started somewhere...
One-day, One-problem at a time!!!
If you feel I have helped, please click on the star to left of post [Add Reputation]
Also....add a comment if you like!!!!
And remember...Mark Thread as Solved.
Excel Forum Rocks!!!
He is having issues with only the single file. I suspect there is some type corruption affecting the copy process.
???
Nmbbnnnnn
Jhgbbbb
Last edited by misterno; 10-31-2022 at 12:20 AM.
By chance, is the file format CSV for MacIntosh and not Windows ?
Ideally...Copy Folder contents at once to other Folder...
Change red snippets to your paths
Or if you want to copy one at a time then...Please Login or Register to view this content.
Please Login or Register to view this content.
Last edited by sintek; 10-31-2022 at 01:51 AM.
Sintek ... thanks for providing misterno a solution.
misterno...No need to quote entire post...just clutters the thread...
Glad to have helped...Tx for rep +
Please remember to mark thread as SOLVED...
Logit...Just giving back...What I was taught...Tx
Last edited by sintek; 10-31-2022 at 02:09 PM.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks