Graphics, Figures & Tables ⇒ Continued caption with captions and longtable
Continued caption with captions and longtable
I've got a table that spans three pages...I haven't been able to produce the "Table (continued)" caption after the 1st page...any help is much appreciated.
Regards,
Desperate Doctoral Student
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[11pt]{article}
\usepackage{fullpage}
\usepackage[pdftex]{graphicx}
\usepackage{rotating}
\usepackage{lscape}
\usepackage{booktabs}
\usepackage{caption}
\usepackage{threeparttable}
\usepackage{longtable}
\date{}
\begin{document}
\begin{center}
\captionsetup{type=table,labelsep=newline,singlelinecheck=false}
\caption{\textit{Q sample}}
\begin{longtable}[p]{c p{14cm}} \toprule
\textit{No.} & \multicolumn{1}{c}{\textit{Statements}} \\ \midrule
\endfirsthead
\caption[]{(continued)}
\multicolumn{2}{c}%\\
\toprule\textit{No.} & \multicolumn{1}{c}{\textit{Statements}} \\ \midrule
\endhead
\bottomrule
\multicolumn{2}{r}{{(\textit{table continues})}} \\
\endfoot
\endlastfoot
1 & It is respectable for academic chemists to be founders of new start-ups based on their research. \\
2 & A key goal for our Center is to effectively translate research into innovations. \\
3 & Academic chemistry ...\\ \bottomrule
\end{longtable}
\end{center}
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
Continued caption with captions and longtable
The longtable has it's very own \caption command so there is no need for the code above. Put the \caption inside the longtable head instead, like here:ricardo wrote: \captionsetup{type=table}
\caption{\textit{Q sample}}
Code: Select all
\documentclass[11pt]{article}
\usepackage{longtable}
\usepackage{booktabs}
\usepackage[textfont=it]{caption}
\begin{document}
\begin{longtable}[p]{c p{14cm}}
\caption{Q sample}\\
\toprule
\textit{No.} & \multicolumn{1}{c}{\textit{Statements}} \\
\midrule
\endfirsthead
\caption[]{Q sample (continued)}\\
%\multicolumn{2}{c}%\\
\toprule
\textit{No.} & \multicolumn{1}{c}{\textit{Statements}} \\
\midrule
\endhead
\bottomrule
\multicolumn{2}{r}{{(\textit{table continues})}} \\
\endfoot
\endlastfoot
1 & It is respectable for academic chemists to be founders of new start-ups based on their research. \\
2 & A key goal for our Center is to effectively translate research into innovations. \\
3 & Academic chemistry ...\\
\bottomrule
\end{longtable}
\end{document}