{external-files} is about external files included in a document, e.g., pictures via \includegraphics, or parts of a document via \input or \include. For questions about files automatically generated by LaTeX (.aux, .log, .out, .toc, ...) use {auxiliary-files}.

learn more… | top users | synonyms

2
votes
2answers
736 views

input filename as caption in listing

I'm working on the following piece of code \newcommand{\mycin}[1]{% new command for icluding piece of code from external files \lstinputlisting{#1} } I want to add a caption that reflects the ...
8
votes
1answer
335 views

Numbers in text, without having to update values from external files by hand?

I am writing a paper discussing numerical results of simulations. I am still tuning those simulations itself, so the results keep changing slightly. I don't want to re-type numbers over from what I ...
9
votes
1answer
159 views

How to read from an external dictionary in LaTeX?

I'm wondering how to define a LaTeX command \x that prints "def1" when I write \x{name1}, reading from an external (dictionary) file having a structure like {name1}{def1} {name2}{def2} etc.
7
votes
4answers
2k views

Using external tables in TikZ

How do I use tabela.xls as a data source to a LaTeX table or even a table made with TikZ with the following command? Note: I wanted to use tabela.xls as a data source for multiple files. Tex and that ...
5
votes
2answers
239 views

how to write content of a command into a file

This question is a possible solution to question Code fails with Emergency stop, when using \expandafter\csname and such in listings, though not really an answer. I have defined a command which may ...
4
votes
1answer
2k views

Using \verbatiminput on filenames with underscores

I'm trying to include some source files using \verbatiminput{}. Some of these filenames have underscores in them. This works fine by default. But if I try to include the underscore package so that I ...
4
votes
1answer
149 views

Adding Source of Document as Footnote with External Files

I have a beamer presentation where I am including a set of external slides using includepdf from pdfpages. I want to be able to add a footnote to each of these external slides, which attributes them ...
8
votes
1answer
757 views

Use bibliography numbers and citation from other file

This question led to a new package: xcite I want to reference to citations from other file. Similar to what xr package does to labels, but I want to apply it for the bibliography. If I'm able ...
3
votes
1answer
158 views

Delimit a single auxiliary file into chunks, and include these at separate places?

I have a LaTeX file for inclusion, automatically generated by a code-documentation tool, so the fact it’s a single file is non-negotiable. However, I want to include it not all at once, but some ...
2
votes
2answers
371 views

How to detect a blank line inserted by TeX when reading an external file line by line?

I want to make a macro to import all TeX input files in a directory in which the input file containing the macro exists. When reading an external file, TeX appends a blank line to the last iteration. ...
4
votes
1answer
674 views

Find a extremal value in external data file with pgfplot

Basically I'm plotting many curves stacked one after the other in pseudo 3D to show transient behaviors. I need every x axis to be at the same place so I use a ymin and ymax optional entry for the ...
32
votes
11answers
9k views

Deleting external/auxiliary files?

Is there a way to make TeX delete files? In my document a lot of auxiliary files are created and it would be wonderful to have them removed after their content has been used.
9
votes
2answers
684 views

How to avoid automatic .tex extension in filenames?

I am in an mildly unfortunate situation in which, because of the way I prepared the files automatically, I ended up with a file to be attached but also another file with the same name but ending in ...
12
votes
3answers
2k views

Create list of all external files used by master LaTeX document?

Is there an easy way to create a list of all external files (complete path) which are used by a LaTeX document (and its "sub-documents") by \input \include \includegraphics ? (may I have forgotten ...
9
votes
1answer
203 views

Parsing a file name

What is the precise syntax for file names in various common distributions? This is relevant for three primitives: \input<filename> (renamed \@@input in LaTeX) \openin<4-bit ...
5
votes
1answer
523 views

How to append data to a temporary file?

I want to create a new temporary file (named main-temp.tex), append data to it multiple times, and import the contents later. I haven't learnt how to use TeX file operation, both reading and writing. ...
5
votes
2answers
1k views

Reading data from an ODS file in LaTeX?

I've been using csvtools to read data from CSV files. Is there any way to read data directly from a ODS file, to put the data into a LaTeX document?
1
vote
1answer
173 views

How to refer to sections in different files? [duplicate]

Possible Duplicate: Cross-referencing between different files I am new to LaTeX. I am using \ref{sec:relat-work-import} to refer to sections in different places in the file. I would like ...
7
votes
4answers
10k views

Inserting a .EMF file into a LaTeX document.

I had a question about a file extension I was dealing with after creating a graphics file using the computing software Maxima. When I created the plot I wanted, I saved the file and it saved as a .EMF ...
4
votes
3answers
375 views

Can i automatically load chapters and sections based on the filesystem?

I was interested in knowing if i can load chapters and sections of my book based on the filesystem. For example: Chapter 1/ Section 1.tex Section 2.tex Section 3.tex Chapter 2/ Section 1.tex ...
1
vote
1answer
234 views

pgfplots: correlation for data values from file works, but with errors

maybe I do not to see the wood for the trees, but I'm always getting error messages for compiling the following pgf code, while the output looks like the way it should. Does anyone see whats wrong ...
13
votes
3answers
1k views

Drawing different tikz shapes parameterized by data from a file

I have a file with three columns of data, x, y, r. # x y r 1 1 0.1 2 2 0.5 3 3 1.2 and so on. I'd like to loop over the rows, and draw a circle at x,y with radius r for each row. I first thought ...
26
votes
3answers
3k views

How to influence the name of the pdf file created with pdfLaTeX (from within the source code)?

I have a source file called 2011-05-27_Myfilename.tex and I'd like to create a PDF file from it called only Myfilename.pdf. Can this be configured from within the .tex file itself? (It seems to be ...
10
votes
2answers
778 views

Space inserted after “\input” call

I've noticed a significant issue with the \input command, it seems. For some reason, I can't seem to prevent it from adding a space after it reads its input. Even if there is no newlines or spaces ...
11
votes
1answer
1k views

How do I make an attached file display like a link?

I'm embedding an external file in my pdf with \usepackage{attachfile2} and\textattachfile[color=1 1 1]{description}{file.pdf}. How can I make the text look the same as it would if I had used the ...
6
votes
1answer
362 views

Accelerating LaTeX packages using a make like functionality

I use gnuplottex package quite a lot to draw graphs, and my own bashful package to write include computer output in a document I write. Yet another package of this sort allows one to include metapost ...
12
votes
2answers
798 views

Parsing files through LuaTeX

This question has two parts: How would one generally parse a file with LuaTeX, assuming the file only holds data that is delimited either by spaces, commas or semicolons. How would you parse the ...
4
votes
1answer
706 views

Tikz externalize + macro's ? Or how would you do it?

I'm currently building courses for some of my college teachers. The aim is to make their Word/MS paint generated study material into high grade Latex/Tikz material. I'm aiming for high consistency in ...
28
votes
2answers
12k views

Cross-referencing between different files

I want to cross-reference between different .tex files, just because I want to put every chapters separately. Let's say in file chapterI.tex I have \label{a} and I want to access this in file ...
12
votes
1answer
547 views

How do I create a macro which reads the content of a file when the macro is defined?

I am trying to do something like: \newcommand{\sometext}{\input{somefile.txt}} This works, but requires inputting the file every time the macro is used in the document. I would like to know a way ...
3
votes
2answers
697 views

Recommended directory structure for separating presentation and content

For my bachelor thesis I am going to structure the files for my LaTeX document in a more sophisticated way, which means I would like to use different folders for different file types. Is there a ...
2
votes
2answers
1k views

TeXShop not finding Gnuplot

I'm working in TeXShop on my mac and I love it. There is one slight problem though. I use TikZ wich sometimes uses gnuplot to create it's plots. One would think that running TeXShop alone is enough ...
4
votes
3answers
355 views

References to lists in theorem-like environments/writing # symbol to files

A little warning in advance: This will be quite lenghty. I spent quite some time over the last few days trying to solve the following problem: I'm typesetting mathematical lecture notes and have used ...
13
votes
3answers
815 views

How can I open a file in “append” mode?

Could not find anything in the TeXBook, but this could be just me. I guess it is always possible to open the file for reading, copy its content to another file, and then continue writing to that ...
5
votes
1answer
1k views

pdfpages and linktodoc

I'm trying to link to a specific page in an external document. This has been discussed previously under the topic, How to link to specified page of an outer pdf document?, and the answer suggests ...
11
votes
1answer
4k views

pgfplot: Datafile format for datetime field

I have a datafile (which I may manipulate to any format), it contains a date-time stamp currently in the form "year-month-day hour:min" and a single variable for each recorded time. When I attempt to ...
0
votes
0answers
534 views

Externalize eps figure with TikZ [duplicate]

Possible Duplicate: Export eps figures from TikZ How make externalize EPS figure with TikZ?
13
votes
4answers
638 views

File copy without expansion

What is the command for file copy? I want to copy the contents of one file into another without any command expansion. The operative system would use copy source target I tried reading the contents ...
43
votes
2answers
11k views

How to include graphics with spaces in their path?

I want to import graphics into my main input file using the macro \includegraphics. It does not work if the filename contains spaces. Include image with spaces in path directory to be processed with ...
15
votes
4answers
3k views

How to iterate through the name of files in a folder

Assume I have many TeX files. For the sake of simplicity, also asssume they are in a single folder or directory. I want to input all files from within my main LaTeX document. Actually I can create a ...
13
votes
2answers
2k views

What is the variable that contains the source file name?

I am writing a package that saves information to an external file. I would like to name that file according to the source one; something like foo.tex -> foo.bar But I cannot find any variable that ...
4
votes
1answer
222 views

Why does the following code run in an infinite loop?

\def\hcAuxText{} \newread\hcInputStream \immediate\openin\hcInputStream=myfile.tmp \loop\unless\ifeof\hcInputStream \read\hcInputStream to \hcAuxLine \let\hcAuxAcumm\hcAuxText ...
26
votes
5answers
11k views

.bib library file in a different directory, how to use? (Mendeley centralised .bib file)

problem Hello All, I have the possibility of a centralised, updated .bib file using Mendeley Desktop. This file will stay updated with all the changes I make using my Mendeley citation software. I ...
1
vote
2answers
396 views

Is it possible to call an external application prior to latex.exe to prepare a new file to be imported from within the (La)TeX input file?

I need to execute an external application prior to executing latex.exe to prepare a new file to be imported from within the (La)TeX input file. From another topic, I got an rough info that we can ...
20
votes
4answers
662 views

How to increase the TeX open file limit?

I noticed that TeX has a open file limit, while using some additional bibliographies with multibib, using hyperref, backrefs and so on (basically only 5 additional newcites were possible in that ...
9
votes
3answers
271 views

Make newlines expand to custom command

I am making a guest list which I will print on a sticker sheet, cut them out, then stick them to envelopes. This means that each guest/guest group will have a bounding box drawn around it as a cutting ...
8
votes
1answer
3k views

How to make \lstinputlisting applicable to file paths with spaces?

I am using the listings package and the path to the source code contains some spaces. For example, the path can be /some dir/sub dir/file 1.txt and \lstinputlisting{/some dir/sub dir/file 1.txt} does ...
5
votes
1answer
574 views

Replace spaces/tabs in an imported .txt file upon import?

I read the answers to this question: Import a text file into LaTeX document, and am now wondering if it's possible to let TeX replace tabs or spaces in that text-file with & for example if you ...
38
votes
2answers
4k views

Can I use an image located on the web in a LaTeX document?

I have tried \includegraphics{http://www.site.com/path/to/figure.png} But this returns the error ERROR: Package pdftex.def Error: File `http://www.website.com/path/to/figure.png' not found. ...
12
votes
2answers
2k views

referencing labels from other files

Sometimes I want to refer (using \ref) a \label from some other tex file. What is the right way to do it? (It's, of course, possible to \include all files in one and then use \includeonly — but it ...