Can somebody help me with this error:
LaTeX /b/c12/cWarning:/b/c0/c Reference `lastpage' on page 1 undefined on input line 24.
/b/c4/cOverfull/b/c0/c \hbox (9.14719pt too wide) has occurred while \output is active
[][]
! Missing number, treated as zero.
<to be read again>
w
l.24 \newpage
My text in LaTeX is below:
\documentclass[a4paper,11pt,oneside]{book}
\usepackage[pdftex]{graphicx}
\usepackage[pdfborder={0 0 0}]{hyperref}
\usepackage{epsfig}
\usepackage{float}
%\usepackage{multicol}
\usepackage{array}
\usepackage[table]{xcolor}
%\usepackage{multirow}
%\usepackage{lastpage}
%\usepackage{amsmath}
\usepackage{caption}
\usepackage[portuguese,brazilian]{babel}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{fancyhdr}
\usepackage{tikz}
\usepackage{afterpage}
\newcommand\blankpage{%
\null
\thispagestyle{empty}%
\addtocounter{page}{-1}%
\newpage}
\hyphenation{ra-dio-gra-fi-a in-dus-tri-al}
%\usepackage{helvet}
%\renewcommand{\familydefault}{\sfdefault}
\usetikzlibrary{matrix,arrows,shapes.geometric,positioning}
\usepackage[hmargin=2cm,top=4cm,headheight=2cm,footskip=1cm,height=23cm]{geometry}
\renewcommand{\headrulewidth}{}
\setlength{\parindent}{1.3cm}
\usepackage{indentfirst} %Determinar que cada primeiro paragrafo seja também indentado
\newenvironment{tquote}{\begin{list}{}
{\setlength{\leftmargin}{13mm}
\setlength{\rightmargin}{0mm}}
\item[]}{\end{list}}
% \widowpenalty=300
% \clubpenalty=300
\input{macros}
\pagestyle{fancy}
\fancypagestyle{plain}{%
\fancyhf{}
\fancyhead[c]{%
\centering
\begin{tabular}{|m{3.5cm}|m{10.0cm}|m{2.5cm}|}
\hline
\centering
\includegraphics[height=1.59cm,width=3.0cm]{logo} &
\centering
\Large{PROCEDIMENTO ESPECIFICO DE \\ PROTECAO RADIOLOGICA} \\
\tiny{SR F.30}&
\centering
{ \scriptsize
PER \numero \\REV. \rev \\Data:\data \\Pagina.\thepage \ de \pageref{lastpage}} \tabularnewline
\hline
\end{tabular}
}
\fancyfoot[R]{
\hrulefill \\
{\scriptsize
Elaboração: \sprNome \\
Supervisor de Proteção Radiológica - \sprRegistro
}
}
}
\pagestyle{plain}
\begin{document}
\input{capa}
\newpage
\tableofcontents
% \mainmatter
% \newpage
\input{Transporte-body}
\end{document}
lastpage... Regardless, could you supply us with a minimal working example (MWE) that we can copy-and-paste and replicate the problem? We don't havemacros.tex, nor any of the other things you\input. – Werner Feb 05 '14 at 18:51