VideoHelp Forum

Our website is made possible by displaying online advertisements to our visitors.
Please consider supporting us by disabling your ad blocker or buy a VSO converter software :)
+ Reply to Thread
Results 1 to 5 of 5
Thread
  1. I have a folder of mp4 files with a video and audio track, with subtitles in srt format in the same location. Is there a way to use a batch file to merge them together in so that the tracks are in this order afterwards
    track1:video
    track2:audio
    track3: subtitles

    When I use this batch file:

    for %%A IN (*.mkv) do (
    "C:\Program Files\MKVToolNix\mkvmerge.exe" -o "remux-%%~nxA" "%%~A" "%%~nA.srt"
    )
    When it's clicked, all it does is close instantly. When I run the batch file from command prompt, it does nothing except clear the input and wait for my next command
    Quote Quote  
  2. Add a new line at the end called "pause" (without quotes). Then the window will not close and you will have time to read error messages. Do you actually have any .mkv files in the directory the .bat file is running in? If the for...do command doesn't find any .mkv files it will skip the actual "loop".
    Last edited by sneaker; 12th May 2017 at 15:20.
    Quote Quote  
  3. ugh i might be an idiot today lol, forgot to change the mkv in the batch to mp4. It didnt give any errors when i tried. will report back with what i find

    edit:I found the way to get it to go from mp4 to mkv successfully, but it includes the original file extension just before mkv "filename.mp4.mkv". Is there any way to stop it from including the mp4 part?
    Quote Quote  
  4. %%~nA.mkv (Without the "x" which is for file extension. You already did that for the .srt ...)

    http://stackoverflow.com/questions/8749637/dos-command-to-sperate-file-name-and-extens...into-variables
    Quote Quote  
  5. Thanks!
    Quote Quote  



Similar Threads