Could somebody help me to find where the error is with "Missing number, treated as zero " in the code below please???

    \documentclass[a4paper]{article}
    \usepackage[final]{pdfpages}
    \usepackage{multido}

    % m page's number for each student (ici 7 pages by student)
    % n total number of student
    % p = n*m total number for all student equal to n*m

           \newcounter{m} 
            \setcounter{m}{7} 
            \newcounter{n}
            \setcounter{n}{5}   
            \begin{document}  
            \multido{\i=0+1}{n}{  
  \includepdf[pages={1-(m-2)},nup=1x2,landscape,signature=36]{DOC-sujet.pdf}
  \includepdf[pages={(m-1)-m},nup=1x2,landscape,signature=4]{DOC-sujet.pdf}

         \addtocounter{m}{7} 
              } 
             \end{document}
  • 1
    I think someone has to flag the question for help of an italic speaker (But I don't really know if we have to flag or just wait for someone to edit). tex.meta.stackexchange.com/a/693/120578. @Kofi if you can speak some English please edit your question yourself – koleygr Dec 12 '17 at 12:28
  • 1
    @koleygr Why do you think than all Italian speakers know French? – marmot Dec 12 '17 at 12:29
  • Crosspost latex.org/forum/viewtopic.php?f=52&t=30731 – Johannes_B Dec 12 '17 at 13:02
  • Sorry that you don't speak french. I have add in the end that I am need help to compile my file in latex. When doing it I have got an error "missing number, treated as zero .Could somebody help me to find where the error is with "Missing number, treated as zero " in the code below please??? – Kofi Wolali Azoumah Sparkofgod Dec 12 '17 at 14:16
  • Another Crosspost – Johannes_B Dec 12 '17 at 18:29

Use multido for all counters:

\documentclass[a4paper]{article} \usepackage[final]{pdfpages}
\usepackage{multido}   % m nombre de page par étudiant(ici 7 pages par étudiant) 
% n nombre total d'étudiant 
% p = n*m  nombre total de page du document 
% m=7   

\begin{document}  
\multido{\iM=7+7,\im=5+7,\iN=6+7}{5}{%  
  \includepdf[pages={1-\im},
     nup=1x2,landscape,signature=36]{DOC-sujet.pdf}
  \includepdf[pages={\iN-\iM},
     nup=1x2,landscape,signature=4]{DOC-sujet.pdf}
} 
\end{document}
  • Can I understund why you have chang m into iM and n into iN and so on? – Kofi Wolali Azoumah Sparkofgod Dec 12 '17 at 14:18
  • i is for integer, that's all. Easier to remember – Herbert Dec 12 '17 at 14:24
  • With my code here are the error I ve got: Missing number, treated as zero } – Kofi Wolali Azoumah Sparkofgod Dec 12 '17 at 14:36
  • Your example or my example? – Herbert Dec 12 '17 at 15:03
  • With mine! With your' s I have many error that I can't handle...because I don't understand very well what you are doing.. – Kofi Wolali Azoumah Sparkofgod Dec 12 '17 at 15:17

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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