I'm using the solution from https://tex.stackexchange.com/a/4952/1403 to input a part of file.tex
into another file.
But I'm getting this error:
at the line \ExecuteMetaData[file.tex]{tag}
.
Here's a MWE. The file to be recalled is:
%<*tag>
\begin{equation} \xymatrix{A\ar@(ul,ur)^\Sigma }\end{equation}
%</tag>
Here is the main file:
\documentclass[a4paper,12pt]{amsbook}
\usepackage{catchfilebetweentags}
\usepackage{xypic}
\begin{document}
\ExecuteMetaData[file.tex]{tag}
\end{document}
The xypic
code being recalled does work if I don't recall it, but rather write the line directly on the main file.
\begin{document}
and\end{document}
) step by step. If the problem occurs in one half and not the other, then halve that half, and so on. It may be tricky in this case, but I think the principle is likely still sound. Once the document body problem is sorted out, then progressively strip out packages that seem, a priori, are unrelated to the problem (e.g., if the problem is not about tables, then table-related packages can probably go). Ideally, the minimal document is a small amount of document body and only a few packages.