1

There is an option to mark the same cross reference in footnote using footnotemark.

Can I do the same for tablefootnote?

MWE:

\documentclass{article}

\usepackage{tablefootnote}



\begin{document}

\begin{tabular}{l}
This is the first line........\tablefootnote{according to amitha}\\
This is second line where I have same footnote \tablefootnote{according to amitha}
\end{tabular}

Here for footnote\footnote{\label{mark}Here its working fine}, here is an optiion
\footnotemark[\ref{mark}].


\end{document}
2

Before the answer, let me explain you why your MWE will never work. According to page 3 of the tablefootnote documentation (tablefootnote.pdf):

If \tablefootnote{...} is used in a tabular environment, which is inside of a (sideways)table environment, everything is fine, but when the tabular environment is not inside of a (sideways)table, the tablefootnote will not work.


As far as I could find, there is no direct equivalent to \footnote-\footnotemark[...] using the tablefootnote package. You can, however, simulate it. First, I provide the direct approach and second, is a command shortcut. (Images cropped to reduce space)

\documentclass{article}

\usepackage{tablefootnote}
\usepackage{refcount}

\begin{document}

First footnote\footnote{\label{mark1}First standard footnote}, 
here is another reference to the first standard footnote \footnotemark[\getrefnumber{mark1}].

\begin{table}[h!]
    \begin{tabular}{l}
    \hline
    This is the 
    first line........\tablefootnote{first table footnote\label{reference footnote}} \\
    %%%%%%%%%%%
    This is second line where I have 
    same first table footnote \textsuperscript{\getrefnumber{reference footnote}} \\
    %%%%%%%%%%%
    This is the 
    third line........\tablefootnote{second table footnote\label{reference footnote two}} \\
    %%%%%%%%%%%
    This is fourth line where I have 
    same second table footnote \textsuperscript{\getrefnumber{reference footnote two}} \\
    \hline
    \end{tabular}
\end{table}

Last footnote\footnote{\label{mark2}Second standard footnote}, 
here is another reference to the second standard footnote \footnotemark[\getrefnumber{mark2}].

\end{document}

Version one of referencing existing tablefootnote

Second way, with a command shortcut:

\documentclass{article}

\usepackage{tablefootnote}

\usepackage{refcount}

\def\tablefootnotemark#1{\textsuperscript{\getrefnumber{#1}}}
%If you prefer \newcommand then use this one
%\newcommand{\tablefootnotemark}[1]{\textsuperscript{\getrefnumber{#1}}}

\begin{document}

First footnote\footnote{\label{mark1}First standard footnote}, 
here is another reference to the first standard footnote \footnotemark[\getrefnumber{mark1}].

\begin{table}[h!]
    \begin{tabular}{l}
    \hline
    This is the 
    first line........\tablefootnote{first table footnote\label{example tablefootnote one}} \\
    %%%%%%%%%%%
    This is second line where I have 
    same first table footnote \tablefootnotemark{example tablefootnote one} \\
    %%%%%%%%%%%
    This is the 
    third line........\tablefootnote{second table footnote\label{example tablefootnote two}} \\
    %%%%%%%%%%%
    This is fourth line where I have 
    same second table footnote \tablefootnotemark{example tablefootnote two} \\
    \hline
    \end{tabular}
\end{table}

Last footnote\footnote{\label{mark2}Second standard footnote}, 
here is another reference to the second standard footnote \footnotemark[\getrefnumber{mark2}].

\end{document}

Version two of referencing existing tablefootnote

I included a second version using \newcommand, in case you have a preference. You could make a similar command shortcut for \footnotemark[\getrefnumber{...}], of course.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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