Changing extensions of "multiple" files...?

Discussion in 'Software' started by mikehende, Jul 6, 2006.

  1. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    Using XP Home edition, I have 150 files in a folder and wish to change the file type or extensions of all of these files from "file" to "flv", do I have to rename each file one at a time or is there a way that I can change all 150 files in one shot?
     
  2. ffreeloader

    ffreeloader Terabyte Poster

    3,661
    106
    167
    rename *.file *.flv You must be in the folder in which you are trying to change the file extensions or you must include the path if you are not.

    However, if you are going to play with things like this why not use regular file extensions such as .txt, .doc, .odt, .pdf, etc...?
     
    Certifications: MCSE, MCDBA, CCNA, A+
    WIP: LPIC 1
  3. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    don't understand ffreeloader, as I've mentioned in my original post, I don't wish to have to rename each individual file to change the extension, I am looking for a way to change all 150 files in one shot or am I misunderstanding you?
     
  4. ffreeloader

    ffreeloader Terabyte Poster

    3,661
    106
    167
    Do you have a computer to use?
     
    Certifications: MCSE, MCDBA, CCNA, A+
    WIP: LPIC 1
  5. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    yes, the one I am on right now writing this message.
    p.s.This is my home pc so I can do whatever experiments from this machine.
     
  6. wizard

    wizard Petabyte Poster

    5,767
    42
    174
    The command freddy has given you will change the extension of all the files without renaming the files.
     
    Certifications: SIA DS Licence
    WIP: A+ 2009
  7. ffreeloader

    ffreeloader Terabyte Poster

    3,661
    106
    167
    Well, I was just wondering why you didn't just try what I showed you.

    If you don't want to use your "real" files create a folder and populate it with a bunch of empty text files. Then navigate to that folder with the cd command and use the rename syntax that I showed you in my first reply.
     
    Certifications: MCSE, MCDBA, CCNA, A+
    WIP: LPIC 1
  8. Jakamoko
    Honorary Member

    Jakamoko On the move again ...

    9,924
    74
    229
    Mike, I don't think it has been mentioned explicitly yet - you should be at a command prompt to do the above, ie click Start > Run then type "cmd" (no apostrophes) ans click OK. Once at a black command prompt screen, simply follow the above first class advice. :)
     
    Certifications: MCP, A+, Network+
    WIP: Clarity
  9. wizard

    wizard Petabyte Poster

    5,767
    42
    174
    ooops. :D
     
    Certifications: SIA DS Licence
    WIP: A+ 2009
  10. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    yes, I did not realize that this was a command to use in DOS, will gie it a try in a short while.
     
  11. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    When the cmd prompt opens up it always shows
    c:\documents and settings\mike>

    I added
    cd \oldies addition

    to change now to
    c:\oldies addition

    which is the folder containing the files in question so now I add rename*.file*.flv so now it looks like this
    c:\oldies addition>rename*.file*.flv

    and I hit enter but I get this message:
    rename*.file*.flv is not recognized as an internal or external command, operable program or batch file

    What am I doing wrong?
     
  12. d-Faktor
    Honorary Member

    d-Faktor R.I.P - gone but never forgotten.

    810
    0
    39
    remember everybody telling you to put a space between the command and the variable?
     
  13. Mr.Cheeks

    Mr.Cheeks 1st ever Gold Member! Gold Member

    5,373
    89
    190
    rename*.file*.flv

    you forgot the space

    rename *.file *.flv
     
  14. wizard

    wizard Petabyte Poster

    5,767
    42
    174
    yes mike, you forgot the spaces.

    so its:

    commandprompt>rename *.file *.flv

    notice the spaces between rename, *.file and *.flv.
     
    Certifications: SIA DS Licence
    WIP: A+ 2009
  15. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    what you guys are telling me suggest to me that I haven't grasped the "space" thing so I guess I will have to go back to that before moving on to anything else, I will address this in a few but first let's deal with the task at hand, what I am seeing in the cmd prompt now looks like this

    c:\oldies addition>rename *.file *.flv

    If this is correct, I am getting this message when I hit enter:

    The system cannot find the file specified

    only thing I can think of is that ffreeloader wrote above
    "You must be in the folder in which you are trying to change the file extensions or you must include the path if you are not."

    Since "Oldies Addition" is the folder and not the files themselves, how do I proceed [if this is the problem]?
     
  16. d-Faktor
    Honorary Member

    d-Faktor R.I.P - gone but never forgotten.

    810
    0
    39
    the folder needs to contain the files with the .file extention.
    [edit] or the files are there but actually don't have a .file extention.
     
  17. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    You're correct, the files in that folder does not have the extensions, I will go change them now and try again.
     
  18. mikehende

    mikehende Kilobyte Poster

    265
    0
    19
    Damn damn damn, now this changes everything, initially I should have stated that the files do NOT have extensions and I am trying to add the .flv extension to all of them, so sorry for this, did not realize this so how does this change things?
     
  19. Mr.Cheeks

    Mr.Cheeks 1st ever Gold Member! Gold Member

    5,373
    89
    190
    whats the actual extension for the files in the folder?
     
  20. d-Faktor
    Honorary Member

    d-Faktor R.I.P - gone but never forgotten.

    810
    0
    39
    if they don't have an extention, then do this:

    ren [space] *. [space] *.flv
    just leave off the "file" part of your previous command.
     

Share This Page

Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.