Xcopy specified file extension only

Posted on 2007-08-08
Last Modified: 2008-01-09
Is there a way to use xcopy to just copy files with a certin file extension for example xcopy only .doc files?
Question by:meszo
    LVL 15

    Accepted Solution

    xcopy *.doc  
    The Asterix stands for all files. Therefore the above command would copy all files with the extension .doc
    LVL 9

    Expert Comment

    Just to add a little more detail to vico1's post above:

    here's an example:
    xcopy c:\Temp\*.doc c:\Temp2 /I

    This command will copy all files ending in doc from the c:\Temp folder into the c:\Temp2 folder.  The /I  (that's a slash "eye") just means that Temp2 is a directory (and not a file).  Just alter the above command to suite the path where you're copying your files from and to.

    Post back if you have any questions!

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Suggested Solutions

    Can I legally transfer my OEM version of Windows to another PC?  (AKA - Can I put a new systemboard in my OEM PC?) Few of us are both IT and legal experts but we all have our own views of Microsoft's licensing rules and how they apply.  There are…
    Being a system administrator some time we require to do things remotely, one of them is installing software. Here I am going to tell you how to install software through wmic (Windows management instrument console). I am not at all saying that this i…
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now