0

This question already has an answer here:

please tell me the necessary packages that I must use to get blue colored cross-referring to Fig.1 and Eq.(1). I want to change the color of Fig.1 from black to blue. Thank you very much in advance.

\documentclass[5p]{elsarticle}


\usepackage{lineno}
\modulolinenumbers[5]

\journal{Journal of \LaTeX\ Templates}

\usepackage{times}


\begin{document}


%\linenumbers

\section{Introduction}
Piezoelectric Fig.1 and Eq.(1) effect has been employed to a very great extent in many applications since its discovery by the Curie brothers.


\end{document}

marked as duplicate by Sebastiano, Troy, Stefan Pinnow, user2478, ebosi Dec 15 '17 at 12:37

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.

  • Hi, please tell me the necessary packages that I must use to get blue colored cross-referring to Fig.1 and Eq.(1). I want to change the color of Fig.1 from black to blue. Thank you very much in advance, – Prakash Dec 15 '17 at 10:04
2

you only need to add the hyperref package. The setup commands also needed are:

\usepackage{hyperref}
    \hypersetup{
        colorlinks   = true,
        citecolor    = blue
    }
  • If I use this code, I get the blue colored number when I cross-refer the Figures and Tables but the word Fig. and Table. is still in black color. Thank you – Prakash Dec 17 '17 at 10:33
  • Hi, @Prakash try using \autoref{} instead of \ref{}. So you do not need to put Fig. or Table. – LambertG Dec 18 '17 at 14:08

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