Windows 10: Copying files

Page 1 of 3 123 LastLast

  1. Posts : 4
    Windows 10 on Desktop PC
       30 Apr 2017 #1

    Copying files


    I have a flash drive with many mp3's on it, however they are split up into various folders. How can I copy all mp3's to my fixed disc without the directories, ie just copy the mp3's without having to access each individual directory. TIA, Mike
      My ComputerSystem Spec

  2. Cliff S's Avatar
    Posts : 21,213
    Win10 Pro, Win10 Pro N, Win10 Home, Win10 Pro Insider Fast Ring, Windows 8.1 Pro, Ubuntu
       30 Apr 2017 #2

    Use the wild card option, an example:

    copy C:\UserName\music\*.* D:\backup

    3 Ways to Copy Files in Command Prompt - wikiHow
      My ComputersSystem Spec

  3. Barman58's Avatar
    Posts : 2,764
    Windows 10 Pro x64 1803 - 17134.5 XP/Vista/Win7/Win8.1 in VM for testing
       30 Apr 2017 #3

    I think you may be better using this slightly modified command if you do not need to move the folders *.mp3 will only copy the MP3 files Whereas *.* will also copy the folders
    Code:
    copy C:\UserName\music\*.mp3 D:\backup
      My ComputerSystem Spec

  4.    30 Apr 2017 #4

    Barman58 said: View Post
    I think you may be better using this slightly modified command if you do not need to move the folders *.mp3 will only copy the MP3 files Whereas *.* will also copy the folders
    Code:
    copy C:\UserName\music\*.mp3 D:\backup
    This is not what OP is asking - OP has mp3 files in many directories and wants to put them all in one directory.
      My ComputerSystem Spec

  5. Barman58's Avatar
    Posts : 2,764
    Windows 10 Pro x64 1803 - 17134.5 XP/Vista/Win7/Win8.1 in VM for testing
       30 Apr 2017 #5

    If this does not work you may need to use robocopy ...

    file - ROBOCOPY - Copy folders content to a single folder - Stack Overflow
      My ComputerSystem Spec

  6.    30 Apr 2017 #6

    The way I would do it is open a command prompt and type (say usb was d drive)

    d:

    cd \

    dir /s /b *.mp3 > mp3.bat

    Then open mp3.bat in notepad and

    1) replace all "d:" with "copy d:"

    2) replace all ".mp3" with ".mp3 d:\mp3files\*.* (can change drive and path of destination - folder must exist)

    3) save and run batch file

    Just tested above (with pdf files in my case and it worked perfectly.
      My ComputerSystem Spec

  7. Cliff S's Avatar
    Posts : 21,213
    Win10 Pro, Win10 Pro N, Win10 Home, Win10 Pro Insider Fast Ring, Windows 8.1 Pro, Ubuntu
       30 Apr 2017 #7

    cereberus said: View Post
    The way I would do it is open a command prompt and type (say usb was d drive)

    d:

    cd \

    dir /s /b *.mp3 > mp3.bat

    Then open mp3.bat in notepad and

    1) replace all "d:" with "copy d:"

    2) replace all ".mp3" with ".mp3 d:\mp3files\*.* (can change drive and path of destination - folder must exist)

    3) save and run batch file

    Just tested above (with pdf files in my case and it worked perfectly.
    Easiest is just to copy the path in file explorer and paste it in.
      My ComputersSystem Spec


  8. Posts : 93
    Windows 10
       30 Apr 2017 #8

    Barman58 said: View Post
    If this does not work you may need to use robocopy
    There’s no switch to stop robocopy from preserving the directory structure. The way to do this in batch is to loop off the results of dir, which can be done directly like so.
    Code:
    for /f "delims=" %%I in (' dir /a:-d /b /s "C:\source\*.mp3" ') do (
        copy "%%~I" "C:\destination\%%~nxI"
    )

    But allow me to advocate for the PowerShell way:
    Code:
    Get-ChildItem 'C:\source' -Include '*.mp3' -Recurse | Copy-Item -Destination 'C:\destination'
      My ComputerSystem Spec

  9.    30 Apr 2017 #9

    Pyprohly said: View Post
    But allow me to advocate for the PowerShell way:
    Code:
    Get-ChildItem 'C:\source' -Include '*.mp3' -Recurse | Copy-Item -Destination 'C:\destination'
    Just tried it - failed with all sorts of error messages about permissions when using C drive.
      My ComputerSystem Spec


  10. Posts : 93
    Windows 10
       30 Apr 2017 #10

    Try changing the paths and the -Include argument, preferably to something that exists.
      My ComputerSystem Spec


 
Page 1 of 3 123 LastLast

Related Threads
Solved Help with copying files to CD in General Support
I cannot figure out how to burn some files to a CD. I put a blank in the drive and try to copy files to the CD by opening a window of the source and the drive as the target. I click and drag the files from the source to the target window and I get...
Homegroup - copying files in Network and Sharing
I want to copy files from the source PC to the destination PC, but I don't want to allow editing or deletion of these files from the destination PC. How do I set this up? Thanks! Tried setting the destination folder as Homegroup > View, but then...
Is there a rugged copy program that can copy a partially corrupted file (*.mpg) from a CD/DVD onto your H/D? What happens is that when the normal windows copy operation encounters that portion of the DVD that is faulty, it tries over and over again...
In Windows 7, it can be a real bother to leave a folder to copy to another drive, with some files in the folder being new versions to replace versions already existing in a same-name folder on the drive that's being copied to... and at some point...
Copying new files stuck at 83% in Installation and Upgrade
Hey everyone. I got my free upgrade to Windows 10 and I tried installing it. But it got stuck at 24%, copying new files 83%. If anyone could help me I'd appreciate it. Thank you
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 01:20.
Find Us