how can i add extension to multiple extensionless files on windows 10 . Powershell command doesn't work

Anonymous
2019-11-03T15:12:54+00:00

how can add extension to multiple file on windows 10 using windows powershell

hi, how can i add extensions to multiple extensionless files on windows 10

///

when i right click on folder  holding shift key then choose powershell because there is no command prompt

and enter this command ren *. *.jpeg it doesn't work even ren * *.jpeg didn't work also

i tried using cmd prompt by from start menu then locating file using cd then file location then typed the first command it worked so what is the right command for windows power shell and if there are any other methods it would be great

Windows for home | Windows 10 | Files, folders, and storage

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes

16 answers

Sort by: Most helpful
  1. Anonymous
    2019-11-04T03:44:47+00:00

    i tried that already not working tried to remove the point the inserting space not working i is a different code i think i don; know why microsoft is using bad complicated codes

    You need to explain what is bad or complicated with this code:

    ren   *   *.jpg

    It doesn't get much simpler than this!

    2 people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2019-11-04T09:31:53+00:00

    If you need to use powershell rather than command prompt, the simplest script I can see to use is:

    gci | ?{!$_.PsIsContainer} | ren -new {$_.name + ".jpeg"}

    This will add the jpeg extension to any file in the target folder, ensure you switch to the correct folder prior to running this using:

    cd [folder name]

    e.g. cd c:\test

    34 people found this answer helpful.
    0 comments No comments
  3. Anonymous
    2019-11-04T22:44:33+00:00

    this commadn wokred just fine. but it is rather complicated command 

    how could i as a normal person memorize it instead of ren * *jpeg ???!!!!!

    coding is so much sick in windows

    0 comments No comments
  4. Anonymous
    2019-11-04T22:46:13+00:00

    did u read the comments ? or the post

    this code works only in command prompt

    and if u right clock a folder with shift of open file menu in any opened folder it will give u powershell instead of command prompt it is micrsoft matter

    1 person found this answer helpful.
    0 comments No comments
  5. Anonymous
    2019-11-04T22:56:40+00:00

    Hi,

    As I explained it would be much simpler to use command prompt for this task, unfortunately Powershell commands can be more complicated but there are many more features.

    I suggest that you saved these commands somewhere and copy/paste when required.

    Regards,
    Ross

    0 comments No comments