46

Question: how do I remove a frame from my presentation?

I am using the beamer package and I just want to remove 1 frame quickly from my presentation because it is not relevant. Is there a quick way to do this? Like

\begin{frame}[exclude]
\end{frame}
WG-
  • 2,860
  • The answer of @dcmst is correct. After my post I also came across this topic, http://tex.stackexchange.com/questions/17816/commenting-out-large-sections. In my case it was also sufficient to use the \iffalse ... \fi statements – WG- Sep 08 '14 at 13:07
  • 5
    I think in the specific case of a beamer presentation the answer here is probably preferable to the general 'commenting out' one. Also, the question is distinct: nice one! – Joseph Wright Sep 08 '14 at 13:09

1 Answers1

53

use <presentation:0>

\documentclass{beamer}

\begin{document}
\begin{frame}<presentation:0>
1
\end{frame}
\begin{frame}
2
\end{frame}
\begin{frame}
3
\end{frame}
\begin{frame}
4
\end{frame}
\begin{frame}
5
\end{frame}
\end{document}

Obligatory gif: enter image description here

The slide number is still incremented by slides hidden in this way. If you don't wish to number hidden slides, add the argument

\begin{frame}<presentation:0>[noframenumbering]
innisfree
  • 598
  • 5
  • 17
d-cmst
  • 23,095
  • 18
    You can omit the presentation: if you want to just hide the slide from any kind of mode (e.g. handout), like \begin{frame}<0>[noframenumbering] – Mitja Sep 14 '17 at 13:28
  • Any idea how to get noframenumbering to work with fragile? – Jo Mo Mar 09 '21 at 14:45
  • @JoMo, that sounds like a question that needs its own SO post. – Paul Wintz Mar 28 '22 at 20:44
  • First comment, from @Mitja, indicates that just putting <0> will work. Right now, it does not in my Latex installation. But the code <presentation:0> works as indicated. – alfeliz Sep 21 '23 at 11:33
  • 1
    The Beamer User Guide suggests in 8.4 that <0> works and also that they automatically get the [noframenumbering] today. You could try <all:0> and see if that does something and maybe look into if the beamer package you have installed is up to date. – Mitja Sep 22 '23 at 14:52
  • "Frames which are hidden with <0> behave like the noframenumbering option and will not be counted for the number of frames (this only applies if no mode is specified, e.g. not for <all:0>)", Beamer User Guide , v3.70, p. 77. – solarchemist Dec 11 '23 at 21:31