{input} is about the \input command which makes LaTeX process the content of a given file basically the same way as if it would be written instead of \input.
Questions tagged [input]
869 questions
63
votes
3 answers
Include data from a .txt verbatim
I am using a finite element program that outputs data in .txt files. And I want to input these data in my LaTeX code. Is there a way to input the data files so that they appear as the program output format?
Program output data file:
LaTeX…
Malthe Eisum
- 3,019
63
votes
4 answers
\input only part of a file
I would like to include part of the contents of a .tex file into a different .tex file. I don't have the option of modifying the file to include. The file to include may change so simply copying and pasting the part I need is not ideal.
Essentially,…
astrofrog
- 1,057
49
votes
4 answers
Path to External Files in Nested \input
Problem
I usually load a helping TeX file that contains my customizations, e.g., usual packages, corporate standard colors, and macros for abbreviations. I want my helping file to also load another external file that is in the same folder. I…
Ali Mehrizi
- 2,631
24
votes
4 answers
how to use \input{file.tex} correctly?
Suppose I have two latex files file1 and file2 with the same preamble and so on. Then I want to create a file called bigfile which just puts the two files together. This is not working for some reason. Therefore I first tried to include just file1,…
Nadori
- 1,865
15
votes
2 answers
how to prevent \input from failing if the file is missing?
I read here (second comment to the question)
When should I use \input vs. \include?
that \@input "does not throw an error if the file does not exist".
If I try
\documentclass{article}
\begin{document}
\@input{toBeIncluded.tex}
\end{document}
I…
Giulioo
- 153
13
votes
2 answers
\input - \return-command
I'm looking for a command like \return with which I can manually exit a TeX file, which is included by \input.
(At the end of my TeX file are some notices, which I sometimes want to print, sometimes not.)
musicman
- 3,559
11
votes
2 answers
Input file folder
In my main LaTeX file I'm using a number of input files which are dynamics (changing the contents). I want to put some of these files in a higher order folder but at the same time don't want to fix it name.
Filefolder\Latexmainfile
how can I change…
user31177
- 1,089
10
votes
1 answer
input files in different directories
I have following example directory structure.
ArticlesWritten
- ArticleA
- - FileOnlyInArticleA.tex
- - Introduction.tex
- - main.tex
- - MainAsChapter.tex
- - RelatedWork.tex
- -
- ArticleB
- …
Atilla Ozgur
- 401
9
votes
2 answers
How to use the contents of a file as a number
I want to create a loop including n images.The number n is the only content of a help file (created by the application that generates the images).
Is it possible to read the contents of the help file and use that as a number variable to set the…
uli_1973
- 1,920
8
votes
1 answer
How can I access the numbers of pages on which input material begins and ends?
Is there a way to access the numbers of pages on which material included using \input begins and ends? Crude approaches along the lines of
\def\myinput#1{%
\typeout{ Input starts on page \thepage}
\input{#1}
\typeout{ End ends on page…
Ian Thompson
- 43,767
8
votes
1 answer
How to \input the part between \begin{document} and \end{document} from another LaTeX file?
Sometimes I want to \input some LaTeX code, which belongs to a standalone LaTeX file.
I would like to input the part between \begin{document} and \end{document}, while skipping the other part.
Hongying
- 569
8
votes
2 answers
How not to load a file repeatedly?
I created a file version.tex with a git log message. This .tex-file is then included in my main.tex file like this:
\renewcommand{\footsnippy}{%
Author Name,
Title of my Book, %
\input{version}
}
because footsnippy is used by the document…
towi
- 2,500
- 2
- 22
- 29
7
votes
2 answers
\input in the reverse order
I wonder if there is a reverse version of input.
For instance, I maintenance a list of things.
list.txt
\myitem{20080103}{a}
\myitem{20090202}{b}
I could do \input{list.txt} and define \myitem in one file to generate an itemized list.
But now I…
rukh
- 73
7
votes
1 answer
\renewcommand of \input for embedding input files without embed ALL source files
I would like to redefine the \input command so that it also embed the input file to the generated pdf. So far I used the code from thi s question (Mark on document where input starts and what is the…
Red
- 10,181
6
votes
1 answer
\graphicspath for Inkscape pdf_tex files
For writing a lecture note, I have put my images in a subdirectory named "image". In the main.tex file I have added \graphicspath{{image/}}. I have also included:
\newcommand{\executeiffilenewer}[3]{%
\ifnum\pdfstrcmp{\pdffilemoddate{#1}}%
…
mkj
- 141