I'd appreciate some help/advice on the following:
Context: I have to generate a bunch of reports that looks all the same in term of their structure.
Objective: Automatize as much as possible the content input of each section along with the title etc.
Working example (main.tex):
Code: Select all
\documentclass[12pt,]{article}
\usepackage[english]{babel}
\usepackage{lmodern,multido}
\title{Report on xyz}
\author{moon61}
% Assuming I have 10 sections
\begin{document}
\maketitle
% Include macro file see below
\input{macro_titles.tex}
% I set a counter going till 10
\multido{\i=1+1,\n=1+1}{10}{
% I define a variable called numV that will take the % values R1 R2 etc
% I assign to numV the corresponding Ri
\def\numV{R\i}
% Then I need to use the content of what is in numV and not numV itself....
\section{Result number \i:\numV }}
Furthermore I'd like to get the input (below) working properly for the content files. Basically They're called detailR1.tex, detailR2.tex etc...
\input{detail\numV.tex}
\end{document}
Having the file called "macro_titles.tex" looking like this
Code: Select all
\def\R1\{title one}
\def{R2\{title two}
Obviously it doesn't work as I need something like "evaluate the function
\numV
".Forecast: My dream is to get the counter limit defined by the number of lines in the file called "macro_titles.tex".
Help much appreciated.
Best
Moon
PS: I've checked on the existing topics and didn't manage to identify a similar problem. If I'm wrong, I just apologize.