Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Basically I have some text:

\section{Section 1}

TEXT TEXT TEXT

Then I have an image:

\begin{figure}
\centering
\includegraphics[scale=0.6]{images/rlexample.png}
\caption{---}
\label{rlexample}
\end{figure}

This image takes a whole page so it's printed on a new page.
I would like to don't have page number on this page (where there is the image)

I have tried this after \end{figure}:

\thispagestyle{empty}

But the page with text got no page number too.

How can I have page number on the page with text but not on the page with the image?

share|improve this question
add comment

1 Answer

up vote 5 down vote accepted

There are two ways: use afterpage or put \thispagestyle{empty} inside the figure environment as commented by Peter.

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{afterpage}
\usepackage{lipsum}
\begin{document}
Here is some text with an equation in it: $f(x)=x^2+3x_0\cdot\sin x$
and the textual content continues into the second line. No other math
content is contained within this paragraph.

\afterpage{%
\thispagestyle{empty}
\begin{figure}
\centering
\includegraphics[width=\textwidth]{images/rlexample.png}
\caption{---}
\label{rlexample}
\end{figure}
}

Here is some text with an equation in it: $f(x)=x^2+3x_0\cdot\sin x$
and the textual content continues into the second line. No other math
content is contained within this paragraph.

\lipsum[1-10]

\begin{figure}
\thispagestyle{empty}
\centering
\includegraphics[width=\textwidth]{images/rlexample.png}
\caption{---}
\label{rlexample}
\end{figure}
\lipsum[11-20]
\end{document}

Note: Putting thispagestyle{empty} inside figure environment may need some \clearpage at appropriate places and may not work properly if [p] in \begin{figure}[p] is used as noted by Enrico. I would advice the use of afterpage though.

The code supplied in comment:

\documentclass[a4paper,12pt,oneside]{article}
\usepackage[utf8]{inputenc}

\usepackage{enumerate}
\usepackage[demo]{graphicx}
\usepackage{afterpage}
\usepackage{lipsum}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@misc{B02,
  author = {Buthor, B.},
  year = {2002},
  title = {Bravo},
}
\end{filecontents}

\title{42}
\author{Jane Doe}
\date{June 2011}

\begin{document}

\maketitle

\section{Introduction}

\subsection{text}

text text \cite{B02} texttext text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text

\afterpage{%
\thispagestyle{empty}
\begin{figure}[p]
\centering
\vspace*{-3cm}
\includegraphics[scale=0.4]{image.jpg}
\caption{caption}
\label{rlexample}
\end{figure}
\clearpage
}

\lipsum[1-10]


\bibliographystyle{plain}
\bibliography{\jobname}
\end{document}
share|improve this answer
1  
The \thispagestyle{empty} method doesn't work for a page of floats, but only for floats that end in the same page where they are declared. –  egreg Nov 22 '12 at 21:59
    
@egreg: Yes it won't work. Added to the answer. Thank you :-) –  Harish Kumar Nov 22 '12 at 22:06
    
tried everything nothing worked –  dynamic Nov 22 '12 at 22:11
    
Take this miminmal example: sharelatex.com/project/50aea3ac3f475e415a1219cf currently the image is printed after the References page –  dynamic Nov 22 '12 at 22:23
    
@HarishKumar: Perfect now it's working. We were missing \clearpage in the figure. –  dynamic Nov 22 '12 at 22:52
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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