Windows Command Line

Discussion in 'Windows 10' started by blueriver649, Dec 29, 2020.

Tags:
  1. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    Hi there,


    How do I use windows command line to delete all specific extension(.SRT) in Directory or folder. Thanks.
     
  2. cuteee

    cuteee MDL Guru

    Joined:
    Oct 13, 2012
    Messages:
    5,013
    Likes Received:
    775
    Trophy Points:
    180
    Code:
    del *.SRT
     
  3. strotee

    strotee MDL Member

    Joined:
    Jan 30, 2011
    Messages:
    120
    Likes Received:
    124
    Trophy Points:
    10
  4. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    I couldn't do it...Here is a screenshot, thanks.
     

    Attached Files:

  5. Enthousiast

    Enthousiast MDL Tester

    Joined:
    Oct 30, 2009
    Messages:
    35,566
    Likes Received:
    59,630
    Trophy Points:
    450
  6. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    How about zoom function ?
     
  7. Enthousiast

    Enthousiast MDL Tester

    Joined:
    Oct 30, 2009
    Messages:
    35,566
    Likes Received:
    59,630
    Trophy Points:
    450
    Why not just create a proper screen? the built-in snipping tool does a great job. I could also go get me some reading glasses :D

    But on topic:
    And include the folder showing the files you plan to delete? You can put a few in a folder and change the filenames if you want, as long as the .srt extension still is there.
     
  8. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    Here is a bigger Screen shot and I would like to delete all those .srt , thanks E.
     

    Attached Files:

  9. Enthousiast

    Enthousiast MDL Tester

    Joined:
    Oct 30, 2009
    Messages:
    35,566
    Likes Received:
    59,630
    Trophy Points:
    450
    Your success folder is directly in the user folder? are the .srt files in the success folder too?

    Try to use:
    Code:
    del /f /q "*.srt"
     
  10. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    Hi E,

    I am trying to delete all .srt in Hacking Videos folder, Screenshot Screenshot 2020-12-29 205315.png Screenshot 2020-12-29 205315.png
     
  11. ch4os

    ch4os MDL Junior Member

    Joined:
    Jan 9, 2010
    Messages:
    96
    Likes Received:
    109
    Trophy Points:
    0
    It‘s still very unclear where your files are exactly. You tried different folders in your screenshots, yet no files were found.

    Are you sure those files are directly in the root of those folders you tried? Or are you trying to delete files in *all* subfolders?

    This will delete all matching files recursively from your current path:
    Code:
    del /s *.srt
    Please be careful with this command, it will delete matching files from all subfolders!

    Have a look at all available parameters with „del /?“ to understand what those parameters do exactly.
     
  12. blueriver649

    blueriver649 MDL Novice

    Joined:
    Sep 6, 2012
    Messages:
    48
    Likes Received:
    3
    Trophy Points:
    0
    Thank you very much ch4os, I need /s parameter to make it work, it work perfectly. Thanks En and other Gents.
     
  13. mdl052020

    mdl052020 MDL Member

    Joined:
    May 31, 2020
    Messages:
    1,048
    Likes Received:
    1,142
    Trophy Points:
    60
    open command prompt on windows & type any search query you want to search for suppose delete
    then your query to know about its commandline switches will be del /? or erase /?
    if you want to query for removing directories then it will be rmdir /? or rd /? (where rm stands for remove & dir stands for directory )
    if you want to make directory then you query will be mkdir /? or md /?
    just put single space using spacebar then /? after your search query & it will result in all the switches you can use plus there usage (description) on right side .