I have defined a new block called Class
in the algorithmicx package. I want to insert a break within this new block for a new page but I'm getting an error:
Package algorithmicx Error: Some blocks are not closed!!!.
Missing number, treated as zero. \End
This is my minimum working example for reproducing the errors:
\documentclass{article}
\usepackage{algorithm}
\usepackage{algpseudocode}
\begin{document}
\begin{algorithm}
\algblock[Class]{Class}{End}
\caption{Class: Part 1}\label{case_class_1}
\begin{algorithmic}[1]
\Class
\Statex
\Function{function 1}{ }
\State do some stuff
\EndFunction
\algstore{bkbreak}
\end{algorithmic}
\end{algorithm}
% BREAK
\begin{algorithm}[h]
\algblock[Class]{Class}{End}
\caption{Class: Part 2}\label{case_class_2}
\begin{algorithmic}[1]
\algrestore{bkbreak}
\Statex
\Function{function 2}{ }
\State do some stuff
\EndFunction
\End
\end{algorithmic}
\end{algorithm}
\end{document}
Errors:
line 32: Missing number, treated as zero. \End
line 33: Package algorithmicx Error: Some blocks are not closed!!!. \end{algorithmic}
missing \documentclass
. Please provide the code of a small complete document, starting from\documentclass
and ending with\end{document}
that really compiles and illustrates your problem