Validating xmltv files

Using the official xmltv.exe

This validation checks whether the file is well-formed as a standalone xml file and additionally checks whether the file confirms to the xmltv standard as defined in the file xmltv.dtd (a text file).

You can download the latest version here

Unzip the zip file to any folder, say d:\xmltv. In the following it is assumed, the files xmltv.exe and xmltv.dtd exist in that folder. Copy the file (say MyTVGuide.xml) you want to validate to the same folder.

Launch windows comandprompt window (aka. DOS-window) and do

d: <Enter> (change to drive d:)

cd \xmltv <Enter> (change to xmltv folder)

xmltv.exe tv_validate_file MyTVGuide.xml <Enter>

If the file is big, the validation can take some time.

NOTE: Even if this validation fails it is possible that Xepg can process the file in some cases. Xepg is opportunistic: it takes the information it knows and ignores the rest. Furthermore, Xepg doesn't care about the order of nodes as is required in the xmltv.dtd and errors in values (e.g .'7. a .' as episode number) are just ignored as well.

Using Xepg

Xepg does not use the xmltv.dtd. If the file is smaller than about 100 MB then in the XMLTV Job Editor select “Microsoft MSXML DOM” as “XMLTV File Reading Engine” and do a Test Import. This is a full validating parser for well-formedness as a standalone xml file. Be aware that Xepg can “hang” during the process. Have patience.

The EasyXML SAX and the OXml SAX are not claimed to be validating parsers so the official xmltv.exe must be used. However, in case of an error message indicating that the file is not legal, this strongly indicates that the file is not well-formed as a standalone xml file. As a quick test try the other one. Also try to uncheck “Strict XML” for the OXml.