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 am applying a longtable environment. I would like to use something like [htbp] in order to put the table in the next page. Every time I do it gives me an error. Now I am solving the problem with a simple \pagebreak. Do you know a better solutions to this problem?

share|improve this question

2 Answers 2

longtablehas no such options because it makes no sense to have a longtable in a floating object. You can use only [lcr] as option for the environment longtable for the horizontal alignment. Use \newpage if you want to start the longtable on the next page. And, of course, do not put the longtableenvironment in a tableenvironment.

share|improve this answer

If you are forcing the page break anyway probably better to use \clearpage rather than \newpage to prevent any tables floating past the longtable and getting out of order.

If you want to avoid a forced page break and want longtable to move to a natural page break (and you are feeling brave) you can do

\usepackage{afterpage}

Then

\afterpage{\clearpage\begin{longtable}.......\end{longtable}}

If the table is very long it might be better (and certainly take up less TeX memory) if you put (just) the longtable in a separate file, say mytable.tex then

\afterpage{\clearpage\input{mytable}}
share|improve this answer

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.