ConvertxtoDVD - Converting large number of .avi at once




I have a query that is a little difficult to explain, so excuse me if doesn’t make sense the first time you read it! Here goes:

I have around 80 avi files that I would like to convert, (each of them are about 300megs and all are xvids). I would like to convert them with the “Medium Quality/encoding speed” option in the “Encoding” section of the “Settings” menu.

I do not need the ConvertXtoDVD menu for these files, in fact all I need are the output VOB files from ConvertXtoDVD to create my own DVD’s later on.

What confuses me is the “Target Size” setting in the “Encoding” section. If I set it to DVD-9 (about 8Gb) and add about 20 files to encode, it appears that ConvertXtoDVD tries to adjust the bitrate it uses for encoding to a very low amount to try and get as many files converted to under the DVD-9 disk size limit.

(Most of the VOB files are about 400-500megs or less, instead of the “normal” 700-800megs I would expect with “medium” settings and a source file of about 300megs initially).

This makes sense - as I’d image a lot of people want to have a DVD create that fits first time onto a DVD-9 disk.

If I only convert, say 2 files, and try the same process, ConvertXtoDVD has no worries about breaching the 8GB limit and so just encodes them at it’s medium setting. (Giving me my normal 700-800meg output file).

My question - can anyone tell me how to encode all 80 avi’s using “medium” as the encoding - without ConvertXtoDVD trying to readjust the bitrate to squeeze it into a predefined size? I have tried playing with the “custom size” box, but this seems to max out at “8500 MB” and doesn’t help.

I would like to be able to go away this weekend - click the convert button and come home to find 80 VOBS all around the 700-800meg mark!

I hope this makes sense. I also hope it can be done!

Thank you.


use a batch as a command line. it means you will have plenty of times the convertxtodvd running for only for 1 file at a time.
the batch program is something requested by several person, it is something we will consider as a free addon in the future.


Thank you for your reply.

You’ve also left a very juicy carrot hanging there, but I’ve not been able to follow up on it.

Whilst I can get the program to launch from the command line with an .avi file loaded, I sure don’t know the rest of the commands required to start processing! Are you able to help.

Thank you for your reply!


OK first the warning.

This is only a work around. I am NOT a programmer and this code is UGLY. Also ONLY tested on Windows XP Professional

I hope this helps some people. I have created a small script using the inbuilt scripting capabilites of Windows XP. I have heard rumours that the scripting service is not found in Windows XP HOME, but as I don’t have the HOME version I can’t be sure.

It works as follows - when run, it loads ConvertXtoDVD with ONLY the first file it finds in the specified directory. It will AUTOMATICALLY start to convert it USING THE SAME SETTINGS AS THE LAST TIME YOU SHUT DOWN CONVERTXTODVD.

Once it has finished converting, it waits til the script closes down ConvertXtoDVD before repeating the process for every other file left in the directory specified.

So how to get and edit the script:

  1. Download the text file attached to this message. It is called “Encode.txt”, you should rename it to “Encode.vbs” (I would have done so but I can’t upload a “.vbs” file on the forum.

  2. Open the “Encode.vbs” with a text editor like “Notepad”.

  3. There are THREE lines that need to be edited to suit YOUR system:

3.1) Set objFolder = objFileSystem.GetFolder(“C:\DIRECTORY-WHERE-AVI-ARE”) ’ <—CHANGE THIS LINE

This should be set to where you have all the avi’s held. Eg C:\Video\AVI ( NO BACKSLASH AT END )

3.2) MinutesToDelay = “65” '<—CHANGE THIS LINE

This value should be changed to a sensible time as it tells the script how long to wait, in minutes, before shutting down convertxtodvd (forceably and even if it’s still encoding the avi) and starting on the next one. Be generous!

3.3)strFullCommand = "C:\PATH-TO-CONVERTXTODVD\ConvertXtoDvd.exe

This line needs just to be told what directory YOUR convertxtodvd resides.

4.)Save the file. Ensure you ONLY have AVI’s in your source directory, and then double click the “Encode.vbs” file to start an unattended conversion.

Any programmers out there, please make my code better and post a better script here if you can. I’ve just done about 60 conversions in the past few days and this script works for me fine - but it isn’t an elegant solution.

Thanks and I hope it helps.

Encode.txt (755 Bytes)


things have been improved, and now you have more option to do it.

/close will close the application once finished.


First of all:
intheknow: Thanks very much for your help, I downloaded that file and gave it ago. Took me a couple of attempts but I did get it to work!

However you have to be careful, I only set the “waiting minutes” to about 50 for my decodes, and some of them hadn’t finished before the program had shutdown and started the next one!!! Still that only happened to 2 of them. Cheers mate.

lapinou - That sounds REALLY promising - what version will that feature be in? Thanks for helping with this!


Sorry disregard - hadn’t read the rest of the posts in this forum…


OK folks for those that need to do multiple avi’s at once here’s a script that works well using the Windows Scripting Host found on windows xp (I’m not sure about the home version, but definately PRO).

[B]REQUIRES CONVERTXTODVD Version 2.0.12 or greater.[/B]

Copy the text below into notepad.


Save as “Encode.vbs

Double click to Run!

====Copy BELOW this line=====

Set WSHShell = WScript.CreateObject(“WScript.Shell”)
Set objFileSystem = Wscript.CreateObject(“Scripting.FileSystemObject”)
Set objFolder = objFileSystem.GetFolder(“C:\AVI-SOURCE-DIRECTORY”)
Set colFiles = objFolder.Files

For Each FileObj in colFiles
strFileName = FileObj.Name
strFullLocation = objFolder & “” & strFilename
strFullCommand = “C:\PATH-TO-CONVERTXTODVD\ConvertXtoDvd.exe /file=”"" & strFullLocation & “”" /auto=true /close"

WshShell.Run strFullCommand, 1, true



Would love to hear from anyone if they find this useful too!


help !!!
every time i try to open the encode.vsb file, i get an error show up in “converttodvd” it says
" file encode.vsb is an unsupported or non avi file".
no matter what i enter in the txt file the directory looks at the directory the encode.vsb is in and not the one i entered in the code ?

please what am i doing wrong ???


Did you change both red lines to match your configuration?


yes i did


Are you trying to open that file with ConvertXtoDVD?
It is meant to be clicked directly from windows explorer, not to be opened by ConvertXtoDVD.


no when i open from windows explorer just get…
“C:\Documents and Settings\Deano\Desktop\films done\encode.vbs” is unsupported or not A/V file" message


What gives that report?

If that report comes from ConvertXtoDVD then something is wrong with your paths or script. If it comes from windows - then something has grabbed vbs-extension and tries to open it as avi.


Do you have windows HOME version? If so that’s why windows doesn’t recognise the .vbs extension.

Download the Windows Script Host (WSH - the program that can understand the Encode.vbs instructions) from here:



Why don’t you edit your encode.vbs file with notepad, copy and paste all the lines into a post here so we can see what you’ve put into your file.


What if you want to convert the first instance with 2 files the next with 1 the next with 3 etc…sorry for wanting everything…

Can [B]Set objFolder = objFileSystem.GetFolder(“C:\AVI-SOURCE-DIRECTORY”)[/B]
be used as a list or a batch text for running different VBS file settings, to go to a different AVI folder.

Like the VBS file has different settings and a text file runs each one in turn after its finished. IE



Can the source directory look in a subfolder list.




Just seen this way of doing it but don`t get how to implement the filelist.txt in the runme.bat
[B](/file" or /fl: filelist.txt) [/B] ???



C:\PATH-TO-CONVERTXTODVD /ConvertXtoDvd.exe C:\111\project1.xToDVD /auto=true /close"

C:\PATH-TO-CONVERTXTODVD /ConvertXtoDvd.exe C:\111\project2.xToDVD /auto=true /close"

C:\PATH-TO-CONVERTXTODVD /ConvertXtoDvd.exe C:\111\project3.xToDVD /auto=true /close"

Of course, every projects has to be prepared in advance.

And it you want the defaults, yes you can use “/file” or /fl: filelist.txt



This will convert both of those files in 1 project (Outputs)…


Hi there,

This is the batch file example I have given.

[B]/file:filename.ext[/B] will convert 1 file.


will convert all files in filelist.txt (But in 1 project, 1 output).

If you wish each files to create it’s own DVD, use the [B]/file:filename.ext[/B] method


I hate to resurrect an old thread, but I’m having some trouble getting intheknow’s or pilotsnipe’s Encode.vbs scripts to work. The error I get is:

Windows Script Host
Script:	C:\Program Files\vso\ConvertXtoDVD\Encode.vbs
Line:	15
Char:	1
Error:	The system cannot find the file specified. 
Code:	80070002
Source: 	(null)


The script itself looks like this (all the file locations are valid):

Set WSHShell = WScript.CreateObject("WScript.Shell")
Set objFileSystem = Wscript.CreateObject("Scripting.FileSystemObject")
Set objFolder = objFileSystem.GetFolder("C:\Documents and Settings\Dan\Desktop\family reunion chicago 2006 ")    ' <---CHANGE THIS LINE
Set colFiles = objFolder.Files

MinutesToDelay = "120"  '<---CHANGE THIS LINE

For Each FileObj in colFiles
    strFileName = FileObj.Name 
    strFullLocation = objFolder & "\" & strFilename
    strFullCommand = "C:\Program Files\vso\ConvertXtoDVD\ConvertXtoDvd.exe /dvdvideo=" & strFullLocation & " /auto=true"  '<---CHANGE THIS LINE
    strShutdown = "taskkill /f /im convertxtodvd.exe"

WshShell.Run strFullCommand, 1, False
Wscript.Sleep(MinutesToDelay * 60000)
WshShell.Run strShutdown, 1, true


Anyone know what the problem may be?