\ref gives Figure 1.1.1, which is not wanted. How do I correct this? Please find attached the style file for immediate reference.
Can anyone help me with the same?
\ref gives Figure 1.1.1, which is not wanted. 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
Code: Select all
\begin{figure}[ht!]
\centering
\includegraphics{Figure5.eps}
\caption{A graphical representation of a permutation $p = (1~3~2~4)(5~7~6)(8) (9~10)$.}
\label{Cyclegraph}
\end{figure}Code: Select all
\@writefile{lof}{\contentsline {figure}{\numberline {1.1}{A graphical representation of a permutation $p = (1\nobreakspace {}3\nobreakspace {}2\nobreakspace {}4)(5\nobreakspace {}7\nobreakspace {}6)(8) (9\nobreakspace {}10)$.}}{{\FolioBoldFont 1}-{\FolioFont 5}}}
\newlabel{Cyclegraph}{{1.1.1}{{\FolioBoldFont 1}-{\FolioFont 5}}}\label inside the \caption environment. Code: Select all
\begin{figure}[ht!]
\centering
\includegraphics{Figure5.eps}
\caption{A graphical representation of a permutation $p = (1~3~2~4)(5~7~6)(8) (9~10)$. \label{Cyclegraph} }
\end{figure}\label always has to be put into the same (TeX) group as the \refstepcounter macro incrementing the counter. Usually \caption uses \refstepcounter inside the same group, so \label after \caption works fine. But the (quite unusual) redefinition of \caption done in enghb2e.sty uses \refstepcounter inside an own group; for that reason only \label inside \caption works correct here since it's the only way getting the \label done inside the same group as \refstepcounter.lavanya wrote:When we use it as above the mentioned problem doesn't arise.
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