Longtable \endfoot 位置错误的问题

Longtable \endfoot 位置错误的问题

在此先感谢大家为我提供解决这个问题所给予的任何帮助......

我正在longtable将几个表格分成几页 - 这些将会放在我的论文附录中......

我的问题是,对于这两个表格,“下页继续”\endfirstfoot出现在表格末尾而不是分页符处.....我希望有人能帮助我,因为我已经为此烦恼了两天!!

抱歉,我的例子太长了,但我认为我应该保留所有的序言,以防其中的某些东西导致了问题,并且希望表格足够长才能看到问题(我有四个类似的表格,它们的行为都相同

这是代码

    \documentclass[a4paper,11pt]{report} %add "twocolumn" if interested
    \usepackage{afterpage,lscape}
      \usepackage{graphicx}
     \usepackage{appendix}
          \usepackage{varioref}
      \usepackage{longtable}
       \usepackage{units}
       \usepackage{float}
     \restylefloat{table}
     \usepackage{listings}
     \lstset{
         language=R,
       basicstyle=\scriptsize\ttfamily,
     commentstyle=\ttfamily\color{gray},
     numbers=left,
     numberstyle=\ttfamily\color{gray}\footnotesize,
      stepnumber=1,
     numbersep=5pt,
     backgroundcolor=\color{white},
        showspaces=false,
    showstringspaces=false,
     showtabs=false,
     frame=single,
      tabsize=2,
       captionpos=b,
       breaklines=true,
       breakatwhitespace=false,
       title=\lstname,
        escapeinside={},
        keywordstyle={},
        morekeywords={}
             }
        \usepackage{upgreek}
        \usepackage{pdfpages} 
         \usepackage{gensymb}
        \usepackage[version=3]{mhchem}
       \usepackage[singlelinecheck=off]{caption}
        \setlength{\abovecaptionskip}{0pt}
        \usepackage{subcaption}
          \usepackage[left=4cm, right=2.5cm, top=2cm, bottom=4cm, includefoot, headheight=13.6pt]{geometry}
          \usepackage{tabularx} % for doing tables easily
          \usepackage{array} % for centering tables...such a pain
           \usepackage{enumerate}
           \usepackage{subfig}
           \usepackage{pdflscape}
           \usepackage[sort]{natbib}
            \let\cite=\citep
            \usepackage[pdftitle={My   Title},pdfpagemode=UseOutlines,colorlinks=true,pdfauthor={STM},bookmarks=true,pdftex=true,linkcolor=black,citecolor=blue]{hyperref}
                                                                                                 \usepackage{cmap,graphicx,epsfig,wrapfig,amsmath,amsfonts,longtable,verbatim}
      \usepackage{amsmath,varwidth,array,ragged2e}
      \newcolumntype{L}{>{\varwidth[c]{\linewidth}}l<{\endvarwidth}}
        \newcolumntype{M}{>{$}l<{$}}
       \def\ds{\mathrm{d}s}

        \parindent 0pt     %indentation set for start of paragraphs
       \parskip 8pt       %between paragraph space
         \usepackage{setspace}
          \linespread{1.3} %\usepackage[hang, small,bf]{caption} % define the title
           %to put a word in italics \textit{word}
          \pagestyle{headings}
        \usepackage{sectsty}
         \chapterfont{\raggedright}
         \chaptertitlefont{\mdseries\raggedright}
        \sectionfont{\mdseries}
           \subsectionfont{\mdseries}
         \subsubsectionfont{\mdseries\itshape}

         \begin{document}

        \begin{titlepage}
        \begin{center}
        \vspace*{2.5in}
        {\Huge amount of boring stuff}
        \par
        \vspace{0.5in}
        {\large Me}
        \par
        \vspace{3in}
        My Thesis
        \par
        \vspace{0.5in}
        2013
        \end{center}
        \end{titlepage}

        testing long table \ref{AICHouseCysti} 

        \hspace*{-1cm}\begin{longtable}{ll}
        \caption[Modelling Process for Human HP10 Positivity]{{\bfseries Comparison of mixed-effects logistic regression risk factor models for human HP10 positivity (cysti)}}\\
        \label{AICHumanCysti}
        Model\protect\footnotemark &  AIC  \\
        \hline
        \endfirsthead

        \multicolumn{2}{c}%
        {{\bfseries \tablename\ \thetable{} -- continued from previous page}} \\
        Model &  AIC  \\
        \hline
        \endhead

        \hline \multicolumn{2}{c}{{Continued on next page}} \\ 
        \endfoot

        \hline
        \endlastfoot


         {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt]  

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 


        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

        {\bf hscysti} \sim other.stud + h20.filter + health.km + other  + health.trav.sch & 159.9 \\
        $ + lat.sum + piped + tw.meat + tran.none   + pork  + tw.pig  + well  + opendef   & \\
        + copro + tw + h2o.tx.none + health.mode  + roof + river + pond & \\
        + undercooked + tran.bike $& \\[3pt] 

       \footnotetext{small blah blah blahl}} 

       \hspace*{-1cm}\end{longtable}
       \end{center}

         \end{document}

相关内容