2

This question already has an answer here:

When I use \ref my output is just the number of the table or letter of the appendix. So for example in my MWE below when I enter See \ref{Test1} my output is See 1.1 and for See \ref{AppendixA} output is See A.

Is there a way to have the output to be See Table 1.1 and See Appendix A?

\documentclass[11pt, a4paper, oneside, oldfontcommands]{memoir}
\usepackage{lipsum} % just for dummy text

\begin{document}
\chapter{This is a test chapter}
hello there, please see \ref{AppendixA}

\begin{table}[h]
\centering
\begin{tabular}{ll}
Test & Table \\
1    & 2     \\
3    &      
\end{tabular}
\caption{Test Table}
\label{Test1}
\end{table}
\lipsum[1] Please see \ref{Test1}

\appendix
\chapter{This is a test Appendix} % Main appendix title
\label{AppendixA} % For referencing this appendix elsewhere, use \ref{AppendixA}
\lipsum[1]
\end{document}

marked as duplicate by Werner, lockstep, Andrew, Henri Menke, Maarten Dhondt Jun 16 '15 at 20:44

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

2

There are several packages which can achieve this, cleveref seems to be the most advanced and most customizable one.

At least if the chapter in their documentation fits:

Given how useful automated cross-reference typesetting is, there are naturally a number of other LaTeX packages with similar goals to cleveref, most notably varioref, fancyref, hyperref’s \autoref command, and (for theorem-like environments) ntheorem with the thref option. (There are many others, but these come closest to providing similar features to cleveref.) However, all have certain deficiencies which cleveref attempts to overcome.

If you want to use cleveref for the start just replace your \ref commands with \cref.

Important note: cleveref should be the last package you load, even after hyperref

\documentclass[11pt, a4paper, oneside, oldfontcommands]{memoir}
\usepackage{lipsum} % just for dummy text

%% All you packages here

\usepackage{hyperref}
\usepackage{cleveref}

\begin{document}
\chapter{This is a test chapter}
hello there, please see \cref{AppendixA}

\begin{table}[h]
\centering
\begin{tabular}{ll}
Test & Table \\
1    & 2     \\
3    &      
\end{tabular}
\caption{Test Table}
\label{Test1}
\end{table}
\lipsum[1] Please see \cref{Test1}

\appendix
\chapter{This is a test Appendix} % Main appendix title
\label{AppendixA} % For referencing this appendix elsewhere, use \ref{AppendixA}
\lipsum[1]
\end{document}

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