and while this processes fine using latex,
it complains when using pdflatex...
it says: Missing number, treated as zero...
How to remedy this?
Thanks.
>I'm using the hyperref package and using this:
>... \footnotemark[\ref{a_labeled_foot:note}] ...
Also this will not work for undefined references
without hyperref. \footnotemark[...] expects a
number, a reference is not a number. But a
possible number can be extracted out of a
reference:
\documentclass{article}
\usepackage{hyperref}
\makeatletter
% \getcountref extracts the raw reference and
% results zero for undefined references.
% Caution: undefined references will not generate
% LaTeX warnings!
\newcommand*{\getcountref}[1]{%
\expandafter\@getcountref\csname r@#1\endcsname
}
\newcommand*{\@getcountref}[1]{%
\ifx#1\relax
0% undefined reference
\else
\expandafter\@car#1\@empty\@nil
\fi
}
\makeatother
\begin{document}
Text\footnote{\label{foo}Hello World}
foo\footnotemark[\getcountref{foo}]
\end{document}
Yours sincerely
Heiko <ober...@uni-freiburg.de>