0

I present a MWE:

\documentclass[12pt]{beamer}
\usetheme{Madrid}
\usecolortheme{beaver}
\usefonttheme{professionalfonts}

\usepackage[backend=biber,style=authoryear,natbib=true,url=false]{biblatex}
\addbibresource{biblatex-examples.bib}


\makeatletter
\let\insertsupervisor\relax
\newcommand\supervisortitle{Supervisor}
\mode<all>
{
\newcommand\supervisor[1]{\def\insertsupervisor{#1}}
\titlegraphic{}
}
\defbeamertemplate*{title page}{supdefault}[1][]
{
\vbox{}
\vfill
\begingroup
\centering
\begin{beamercolorbox}[sep=8pt,center,#1]{title}
    \usebeamerfont{title}\inserttitle\par%
    \ifx\insertsubtitle\@empty\relax%
    \else%
    \vskip0.25em%
    {\usebeamerfont{subtitle}\usebeamercolor[fg]    
{subtitle}\insertsubtitle\par}%
    \fi%     
\end{beamercolorbox}%
\vskip1em\par
\begin{beamercolorbox}[sep=8pt,center,#1]{author}
    \usebeamerfont{author}\insertauthor
\end{beamercolorbox}
\ifx\insertsupervisor\relax\relax\else
\begin{beamercolorbox}[sep=8pt,center,#1]{author}
    \usebeamerfont{author}\supervisortitle:~\insertsupervisor
\end{beamercolorbox}\fi
    \begin{beamercolorbox}[sep=8pt,center,#1]{institute}                    
\usebeamerfont{institute}\insertinstitute
    \end{beamercolorbox}
    \begin{beamercolorbox}[sep=8pt,center,#1]{date}
        \usebeamerfont{date}\insertdate
    \end{beamercolorbox}\vskip0.5em
    {\usebeamercolor[fg]{titlegraphic}\inserttitlegraphic\par}
    \endgroup
    \vfill
}

\title[main]{main document}
\author{me}
\supervisor{supervisor}

\AtBeginSection{%
    \begin{frame}[allowframebreaks]
    \frametitle{Outline}
    \tableofcontents[sections=1-2,,currentsection]
    \framebreak
    \tableofcontents[sections=3-5,,currentsection]
\end{frame}
}

\setbeamertemplate{bibliography item}[text]
\setbeamercolor{section number projected}{bg=white,fg=red}
\setbeamercolor{subsection number projected}{bg=white,fg=red}
\setbeamercolor*{item}{fg=red}
\begin{document}

\begin{frame}
\titlepage
\end{frame}

\begin{frame}
\frametitle{Outline}
\tableofcontents[sections=1-2]
\end{frame}

\begin{frame}
\frametitle{Outline}
\tableofcontents[sections=3-5]
\end{frame}

\section{References and Acknowledgements}
%\subsection{References}
\begin{frame}
test
\nocite{*}
\printbibliography
\end{frame}
\subsection{Acknowledgements}
\end{document}

Updated MWE (4/2/18) I ran this MWE and found the same error. Please advice.

moewe
  • 175,683
Marvin
  • 21
  • 3
  • 7
    You should run biber not bibtex. https://tex.stackexchange.com/questions/154751/biblatex-with-biber-configuring-my-editor-to-avoid-undefined-citations – Ulrike Fischer Feb 02 '18 at 18:26
  • 3
    It should probably be citestyle=authoryear and beamer does not have a 13pt option. – samcarter_is_at_topanswers.xyz Feb 02 '18 at 18:40
  • I've corrected accordingly, as adviced, but I'm told that biber.sty is not found despite the fact that I have miktex.biber.bin installed and updated. – Marvin Feb 03 '18 at 13:14
  • Where do you get a message about biber.sty? No such file exists, if you edit your document to incorporate samcarter's suggestion things should work fine and not search for biber.sty. Now the Error: Command crashed is more interesting. Double-check your settings with https://tex.stackexchange.com/questions/154751/. Can you try to run biber document (assuming your .tex file is called document.tex) from the command line and check the output? Is there are .blg file? What does it say? – moewe Feb 03 '18 at 16:45
  • @moewe it seems I previously misunderstood the message for biber. In anycase, I've double checked the settings and followed the instructions to run PdfLatex, Biber, then the error hits me.

    Assuming I'm right about how to run the command from the terminal, type: biber document , no .blg file was found.

    – Marvin Feb 03 '18 at 17:01
  • But when you type biber document in the terminal what is the message? – moewe Feb 03 '18 at 17:03
  • Am I doing it wrong.. cause I didn't get any message following that some how. On the TexStudio log it's shown: No file main.bbl. Empty bibliography There were undefined references. Please (re)run Biber on the file:(biblatex) main(biblatex) and rerun LaTeX afterwards. – Marvin Feb 03 '18 at 17:06
  • Do you really run biber document from the command line, or do you run it from your editor? If you run it from the command line you will see diagnostic output. Please show that output. The output you get from your editor might be filtered an incomplete. Please show the unfiltered output. What you showed in your last comment are LaTeX's warnings, not Biber's warnings. – moewe Feb 03 '18 at 17:09
  • @moewe From TexStudio, I go to Tools, Open Terminal and type in biber main right? That's what I did. Sorry I'm really not too familiar with this. – Marvin Feb 03 '18 at 17:11
  • What OS do you use? Windows, Linux or Mac OS X? Please open the terminal from your OS navigate to the folder containing your .tex file, using the cd command. And then type in biber main. – moewe Feb 03 '18 at 17:12
  • I use Windows. So it seems some how that The code execution cannot proceed because cygwin1.dll was not found. I'm using Windows 10. – Marvin Feb 03 '18 at 17:22
  • OK. Press Windows+R. Somewhere on your screen a small box should appear type in cmd and press enter. A command line window should appear. In that window use cd to navigate to the folder where your .tex file resides. Once you are inside that folder with your command line execute biber document. For help on the command line, see https://www.digitalcitizen.life/command-prompt-how-use-basic-commands, https://www.howtogeek.com/235101/10-ways-to-open-the-command-prompt-in-windows-10/ – moewe Feb 03 '18 at 17:39
  • I did that and encountered the cygwin.dll was not found error. and another .dll error. It seems I've managed to rectify the problem by installing cygwin and copying the files to where Biber.exe resides. Now I get this /biber: error while loading shared libraries: cygperl5_22.dll: cannot open shared object file: No such file or directory on my cmd. – Marvin Feb 03 '18 at 17:42
  • Mhhh, that sounds like you got the Cygwin binary of Biber instead of your TeX live/MikTeX version. Do you use TeX live or MikTeX? What does the command line respond if you type where biber? – moewe Feb 03 '18 at 17:49
  • I use MikTex. where biber gives: C:\Program Files\MiKTeX 2.9\miktex\bin\x64\biber.exe Do you mean I should possibly reinstall MikTex? What I did to rectify the cygwin.dll not found error was to install Cygwin and the copying the missing files over. Was that the right move?

    I'm attempting to update MikTex to see what happens.

    – Marvin Feb 03 '18 at 17:53
  • Mhhh. AFAIK MikTeX's Biber does not need Cygwin, so it should not complain about it. I don't think I have any Cygwin on my machine and the Biber installed by MikTeX works just fine for me. If you installed Biber manually that could explain the problem if you installed the Cygwin Biber binary instead of the 'normal' Windows binary. But if you used MikTeX's package manager you should get the correct version. Of course you can try to update and to remove Biber and reinstall using the package Manager. – moewe Feb 03 '18 at 18:02
  • After updating MikTex, that seemed to have sorted out the problem. bbl file was created. So, following the pdfLatex, then biber, then pdfLatex procedure.. On the second pdfLatex run, it suggested that I have an Extra }, or forgotten \endgroup. – Marvin Feb 03 '18 at 18:02
  • Ha! There will be a line just above that error message, what does it say? – moewe Feb 03 '18 at 18:03
  • ("C:\Program Files\MiKTeX 2.9\tex\latex\amsfonts\umsa.fd") ("C:\Program Files\MiKTeX 2.9\tex\latex\amsfonts\umsb.fd") (C:\Users\clare\AppData\Roaming\MiKTeX\2.9\tex\latex\esint\uesint.fd) ("C:\Program Files\MiKTeX 2.9\tex\latex\jknappen\ursfs.fd") (main.bbl) (main.nav) [1{C:/ProgramData/MiKTeX/2.9/pdftex/config/pdftex.map} <./crest.png> ] (main.toc) [2] (main.toc) [3] (main.toc) (main.toc) [4] [5] [6] [7] <wip.png, id=253, 488.82625pt x 438.63875pt> [8 <./wip.png>] [9] [10] (main.toc) (main.toc) [11] [12] (main.toc) (main.toc) – Marvin Feb 03 '18 at 18:05
  • I managed to find the error.. seems to have been the line: \AtBeginSection{% \begin{frame}[allowframebreaks] \frametitle{Outline} \tableofcontents[sections=1-2,,currentsection] \framebreak \tableofcontents[sections=3-5,,currentsection] \end{frame} }

    After changing it to \AtBeginSection[]{%, it was able to compile. Thanks lots @moewe

    – Marvin Feb 03 '18 at 18:44

1 Answers1

2

I managed to find the error.. seems to have been the line:

\AtBeginSection{%
\begin{frame}[allowframebreaks] \frametitle{Outline} 
\tableofcontents[sections=1-2,,currentsection]
\framebreak 
\tableofcontents[sections=3-5,,currentsection]
\end{frame}
}

After changing it to

\AtBeginSection[]{%

it was able to compile.

Many thanks to @moewe, I guess the problem was partly with updating MikTex and then with this. I'm not sure why the missing [] became an issue given that I copied the para from elsewhere though.

Marvin
  • 21
  • 3
  • 1
    Well \AtBeginSection is executed whenever you start a new \section. \printbibliography starts a new (starred) section (\section*) as well. But since \printbibliography is called from within a frame you produce a frame in a frame. That is just wrong. – moewe Feb 03 '18 at 18:50
  • I see.. so the [] rectifies that? – Marvin Feb 03 '18 at 18:52
  • 1
    If you add [] the \AtBeginSection does nothing for the starred \section* command which \printbibliography uses. – moewe Feb 03 '18 at 18:52