Hi Guys,
I want to to know if is possible Copy Excel files from one Folder to another based in a list.
For example I have several files in one location . But I have a list name of some files to be extracted from this location and to put in another location.
Location 1:
File1.xls
File2.xls
File3.xls
File4.xls
File5.xls
List of files I want to move :
File2.xls
File3.xls
Location 2: (expected location)
File2.xls
File3.xls
Copy Excel files from one Folder to another based in a list
Moderators: Hacker, petermad, Stefan2, white
-
- Junior Member
- Posts: 2
- Joined: 2022-09-29, 13:02 UTC
Copy Excel files from one Folder to another based in a list
Last edited by Jose.Pizarro on 2022-09-29, 14:21 UTC, edited 1 time in total.
Re: Copy Excel files from one Folder to another based in a list
"Background transfer manager" is what you are looking for.
mk:@MSITStore:TOTALCMD.CHM::/options_background_transfer_manager.htm
mk:@MSITStore:TOTALCMD.CHM::/options_background_transfer_manager.htm
-
- Junior Member
- Posts: 2
- Joined: 2022-09-29, 13:02 UTC
Re: Copy Excel files from one Folder to another based in a list
Hi ,
I tried to use this function but I can select the specific files I want to move from one folder to another one.
I tried to use this function but I can select the specific files I want to move from one folder to another one.
PowerShell: Copy files based on a list
Jose.Pizarro Hello and welcome to the forum.
FROM:
Location 1:
File1.xls
File2.xls
File3.xls
File4.xls
File5.xls
BASED on List.TXT (be sure the names match to the real names):
File2.xls
File 3.xls
TO:
Location 2: (expected location)
File2.xls
File3.xls
Try this:
- go in TC to your "Location 1"
- open Command prompt from Commands menu
- type powershell and enter
- use the below three commands:
Set-Location 'Location 1' (((used TAB completion)))
$TargetLoc = "D:\rive\full path\to\Location 2" (((folder must exist)))
Get-Content .\LIST.txt | ForEach-Object{ Copy-Item $_ $TargetLoc}
Example:
- Commands menu > Open Command prompt
- powershell <ENTER>
- PS C:\temp\Copy files from a list>
- PS C:\temp\Copy files from a list>CD '.\Location 1\'
- PS C:\temp\Copy files from a list\Location 1>$TargetLoc = "C:\temp\Copy files from a list\sub folder\Location 2\"
- PS C:\temp\Copy files from a list\Location 1>GC .\LIST.txt | ForEach{ COPY $_ $TargetLoc }
- PS C:\temp\Copy files from a list\Location 1>
Done
FROM:
Location 1:
File1.xls
File2.xls
File3.xls
File4.xls
File5.xls
BASED on List.TXT (be sure the names match to the real names):
File2.xls
File 3.xls
TO:
Location 2: (expected location)
File2.xls
File3.xls
Try this:
- go in TC to your "Location 1"
- open Command prompt from Commands menu
- type powershell and enter
- use the below three commands:
Set-Location 'Location 1' (((used TAB completion)))
$TargetLoc = "D:\rive\full path\to\Location 2" (((folder must exist)))
Get-Content .\LIST.txt | ForEach-Object{ Copy-Item $_ $TargetLoc}
Example:
- Commands menu > Open Command prompt
- powershell <ENTER>
- PS C:\temp\Copy files from a list>
- PS C:\temp\Copy files from a list>CD '.\Location 1\'
- PS C:\temp\Copy files from a list\Location 1>$TargetLoc = "C:\temp\Copy files from a list\sub folder\Location 2\"
- PS C:\temp\Copy files from a list\Location 1>GC .\LIST.txt | ForEach{ COPY $_ $TargetLoc }
- PS C:\temp\Copy files from a list\Location 1>
Done
Re: Copy Excel files from one Folder to another based in a list
You can use menu option Mark/Load Selection From File to select the files you want to copy.Jose.Pizarro wrote: 2022-09-29, 13:08 UTC I want to to know if is possible Copy Excel files from one Folder to another based in a list.
For example I have several files in one location . But I have a list name of some files to be extracted from this location and to put in another location.
You can also use the LOADLIST command (for example by creating a button) to load the files as search results and then copy them.
Is that helpful or do you want something else?