views:

36

answers:

1

Hello,

I would like to create a new environment to print a header and a footer between sections of a table.

I did this:

\documentclass{article}

\usepackage{longtable}

\newenvironment{env}{Heading&&& \\}{\hline \\}

\begin{document}

\begin{longtable}{p{7cm}lrr}
    \begin{env}
        Content&b&c&d
    \end{env}
\end{longtable}

\end{document}

but I get insulted by the compiler. See here for the complete output.

Does someone see the problem ?

+1  A: 
Zack