Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm using supertabular in multicols enviroment based on this thread's accepted answer multicolumn long table or enumeration. But there is sometimes header and empty table body left in new column/page (eg. when i change counter "n" to 19 - first column is full and only header is in second column). I've also tried this solution How to disable pagebreak on \hline in supertabular? but it doensn't help. Number of rows I create is arbitrary. Is there a way to remove these headers with no body (without removing all headers)?

EDIT: example

    \documentclass{article}
    \usepackage[margin=1in]{geometry}
    \usepackage{xcolor,supertabular,multicol}
    \newcount\n
    \n=0
    \def\tablebody{}
    \makeatletter
    \loop\ifnum\n<19
            \advance\n by1
            \protected@edef\tablebody{\tablebody
                    \textbf{\number\n.}&
                    \hfill T\hfill\hfill F\hfill\hskip0pt\endgraf
                    \vskip.5\baselineskip
                    \color@begingroup
                    \color{black!20}
                    \hrule height3ex
                    \color@endgroup
                    \tabularnewline
            }
    \repeat
    \makeatother
    \pagestyle{empty}
    \begin{document}
    \begin{multicols*}{2}
    \let\mcnewpage=\newpage
    \makeatletter
    \renewcommand\newpage{%
            \if@firstcolumn
                    \hrule width\linewidth height0pt
                    \columnbreak
            \else
                    \mcnewpage
            \fi
    }
    \makeatother
    \tablehead{Item \#&\\}
    \begin{supertabular}{lp{1.5in}}
    \tablebody
    \end{supertabular}
    \end{multicols*} 
    \end{document}
share|improve this question
    
Welcome to TeX.sx! Please add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. –  Jubobs Mar 17 '13 at 10:47

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.