Questions tagged [xr]

package implements a system for eXternal References (cross referencing to any `\label`s in external files)

Filter by
Sorted by
Tagged with
0 votes
0 answers
57 views

Cross referencing from a different Overleaf project

I have two Projects, lets call them Project_A and Project_B in Overleaf. Project_A in overleaf has many tex files and so does Project_B. Could a cross reference be made in Project_A such that we could ...
user avatar
0 votes
0 answers
53 views

Problem with cross-referencing in Overleaf

I am working in Overleaf and I have a project folder with 4 documents: Main_paper.tex File1.tex File2.tex Additional_tables.tex I have to include Main_paper as external document in File1 and ...
user avatar
  • 1
0 votes
0 answers
37 views

What is the most difference between zref and xr pckages?

I am using the following codes to exploit main.tex's label of equation, figure, table, etc. and citation number. \usepackage{zref-xr} \zxrsetup{tozreflabel=false, toltxlabel=true, verbose} \...
user avatar
  • 593
0 votes
2 answers
35 views

`\nvrightarrow` causes an error when it is used in the title of a definition and is referenced from another file

The following code is saved in test.tex: \documentclass{scrartcl} \usepackage{unicode-math,xr-hyper,hyperref,cleveref} \newtheorem{definition}{Definition} \begin{document} \begin{definition}[$\...
user avatar
  • 8,684
0 votes
0 answers
33 views

How to add an automatic prefix/suffix to references that point into another file?

Consider two pieces of LaTeX code. The first one, saved in a file named test.tex, contains a single, labeled theorem: \documentclass{scrartcl} \newtheorem{theorem}{Theorem} \usepackage{hyperref} \...
user avatar
  • 8,684
0 votes
1 answer
42 views

Referencing across files using xr-hyper fails

I saved the following LaTeX code in test.tex. \documentclass{scrartcl} \newtheorem{theorem}{Theorem} \begin{document} \begin{theorem}[My 1st Theorem]\label{thm} A \end{theorem} \end{document} I ran ...
user avatar
  • 8,684
0 votes
1 answer
179 views

How can I enforce creation of *.aux files?

I want to write a thesis using subfiles and xr for external references. I use subfiles because that allows me to compile chapters separately without having to compile the whole thesis. My problem is ...
user avatar
  • 1
1 vote
1 answer
114 views

siunitx version v3.0.2 with xr-hyper

I am typeset the multivolume book. Simplest form looks like: main file for volume one (vol01.tex) \documentclass{scrbook} \usepackage{xr-hyper} \usepackage{siunitx} \usepackage{graphicx} ...
user avatar
  • 3,516
2 votes
0 answers
100 views

Include bibliography of xr (xcite) citations, that only contains the relevant entries

Short description of my Question: I am using the xr or xcite package in my derivative project supplementary.tex to give references/citations the same number that they already have in an external ...
user avatar
  • 613
0 votes
0 answers
82 views

Issues in hyperlink to an external document

I have two latex files: one for the actual paper and one for the appendix. In the paper, I want to refer to section of the appendix. I follow what I found around on referring to external dcouments but ...
user avatar
  • 307
1 vote
0 answers
14 views

Sub file references main file, but references do not appear when compiling main file

I am trying to write a large document, and for the sake of organized editing, it makes sense to have each chapter as a standalone document. I am using the standalone package to accomplish this. I have ...
user avatar
0 votes
0 answers
44 views

Latex and file management: chained \include{...} and reference to active directory

For each chapter of a document I am working on I have a separate folder, and all folders are contained in a common superfolder, together with a file main.tex which should put them all together. ...
user avatar
  • 101
0 votes
0 answers
52 views

Save a version of .aux file

I want to use a specific version of the .aux file. So I want to save this version for an eventual use with the xr package. Is there a way to do this task ? Note that the origin of this problem is from ...
user avatar
1 vote
1 answer
170 views

Warning in REVTeX 4.2 for references to an external document: "... has been referenced but does not exist, replaced by a fixed one"

First, I build the following external document, ExternalDoc.tex file, 3+ times. \documentclass[prl,aps,10pt]{revtex4-2} \usepackage{amsthm} \theoremstyle{definition} \newtheorem{thm}{Theorem} \...
user avatar
0 votes
1 answer
177 views

Can Overleaf accommodate pre-fixes for xr-hyper (e.g, \myexternaldocument[ext1-]{path...})

Short version: when using xr or xr-hyper on Overleaf, is it possible to add prefixes to external documents to avoid multiple defined labels (as defined here)? Longer version: I'm drafting a review ...
user avatar
  • 103
0 votes
1 answer
44 views

Package xr prints ref number then label

Here's my MWE. \documentclass[12pt]{article} \usepackage[T1]{fontenc} \usepackage[margin=2.4cm]{geometry} \usepackage{% amsmath, amsfonts, amsthm, mathpazo, tgbonum, xr, ...
user avatar
  • 1,359
0 votes
0 answers
57 views

How to use -cd label in latexmkrc when "No file C1.aux LABELS NOT IMPORTED." error occured

I just get No file C1.aux LABELS NOT IMPORTED. error when I try to use \usepackage[subpreambles=true]{standalone} and \externaldocument{C1} commands, in order to quote from another latex files. I'm ...
user avatar
1 vote
0 answers
385 views

xr package not working properly

I'm trying to use the xr package, and I'm having problems. My document is \documentclass[11pt,a4paper]{article} \usepackage{xr} \externaldocument{ch04} \begin{document} Exercice - Page \pageref{ex3....
user avatar
  • 225
0 votes
1 answer
249 views

reference external figures from supplementary inside overleaf

I try to reference external figures from the supplementary information inside the main text. How to reference figures that are in the supplementary content in main text? describes an approach I try to ...
user avatar
1 vote
1 answer
152 views

Deactivating Hyperlinks to External Documents with Cleveref

My question is quite similar to the one asked here. Also, I found a solution using \ref here. I couldn't find a solution for \cref however. The setting: I have large file with many chapters, which ...
user avatar
  • 111
1 vote
0 answers
305 views

Getting xr and xr-hyper to ignore the bibliographies

Now that xr and xr-hyper allow \cite to refer to \bibitems in the external document, is there a way to get these packages to ignore the \bibitems of the external document? In other words, is there an ...
user avatar
  • 2,602
0 votes
0 answers
110 views

hyperref external reference

I want to reference external documents using hyperref on the files test1 and test2 below. Presumably for security reasons, the links don't work. With MacOs Preview nothing happens and Adobe Reader in ...
user avatar
1 vote
0 answers
80 views

Standalone class and Cross referencing

Is the standalone package compatible with the crossref (xr) package? This has been asked before, but the answer does not work for me. MWE: main.tex \documentclass[]{article} \usepackage{standalone} \...
user avatar
  • 43
0 votes
0 answers
25 views

Referencing my own .tex-files

I am trying to reference doc1.tex in doc2.tex inside the same project on overleaf. I have seen several posts here, but they were all not detailed enough for me. I am very new to LateX. So far I have ...
user avatar
1 vote
0 answers
107 views

Configure latexmk to work recursively with files living in different folders

This is a follow up on How to configure latexmk to work recursively? (PDF Thumbnails) and latexmk with external references. Let me first say what I'm trying to achieve. I have a latex project that ...
user avatar
  • 167
1 vote
2 answers
2k views

"Package xr warning: No file file4.aux LABELS NOT IMPORTED" – What's wrong?

I'm working on an article with tons of appendices that we need a cross referencing system for. Since we user hyperref, I gave the xr-hyper package a try. After MANY attempts, I got it to work with ...
user avatar
3 votes
2 answers
4k views

Using the xr package and - missing aux file? "Warning: No file SupplementalMaterial.aux LABELS NOT IMPORTED"

I'm using Overleaf to write a paper with supplementary material and have been having substantial trouble with separating out Supplemental Material while maintaining references. My MWE is as follows - ...
user avatar
  • 175
1 vote
1 answer
241 views

{}\edef \Hy@tempb {cite.\XR@prefix error when citing same bibtex entry in \externaldocument

I have the following .tex file in a folder main.tex --- \documentclass[11pt]{article} \usepackage{hyperref} \title{} \author{} \begin{document} \maketitle \cite{entry} \bibliography{bib}{} \...
user avatar
  • 161
1 vote
0 answers
47 views

xr package and pgfplots/tikz

I'm using tikz/pgfplots to draw my figures. Usually, my figure is a standalone file that I compile and in my main file, I simply import the pdf with \includegraphcis. I now want to refer to curve in ...
user avatar
2 votes
0 answers
48 views

Use text passages including references of one .tex file in another .tex file

I (teacher at university) plan to create a questionnaire based on the following MWE questionnare.tex. The important point is that some of the questions refer to each other. \documentclass[DIV=12]{...
user avatar
  • 21
5 votes
1 answer
765 views

How do I reference sections in other subfiles?

I cannot figure out how in the world I am suppose to reference other sections in subfiles. I have prepared a simple example below: main \documentclass[12pt,letterpaper]{article} \usepackage[utf8]{...
user avatar
  • 261
1 vote
1 answer
429 views

Unable to reference figure from one subfile to another subfile when compiling ONLY the subfile

I have the following files in Overleaf: main.tex in root directory: \documentclass[conference]{IEEEtran} \usepackage{xr} \usepackage{subfiles} \begin{document} \section{Methodology} \label{...
user avatar
  • 129
3 votes
1 answer
299 views

Avoiding expansion of referenced captions when cross-referencing external documents with TeX4ht

This is a follow-up question to another question. The selected answer proposes the use of zref-xr, which works fine for PDF output, but has its limitations when using TeX4ht: the configuration via \...
user avatar
  • 350
1 vote
1 answer
807 views

Handling main text and supplementary information crossreferencing each other on arXiv

A typical example when writing a paper is that you have a main document main.tex and a document containing supplementary information si.tex. Both documents are stand-alone in the sense that they ...
user avatar
1 vote
1 answer
696 views

Cross-reference with `xr` package and final PDF combination?

So I have been using cross-references so far in Overleaf using this idea from StackExchange, which was adapted in Overleaf itself here. My question is, when I am finally combining main.tex and SI.tex ...
user avatar
  • 111
0 votes
1 answer
201 views

How to number labeled equations with different files?

I have a file main.tex \documentclass{article} \usepackage{xr-hyper} \usepackage{hyperref} \usepackage{mathtools} \mathtoolsset{showonlyrefs} \begin{document} \begin{equation}\label{sec:mytitle} 1 +...
user avatar
1 vote
1 answer
454 views

`xr` Cross-Reference: Change Colour for External References Only

I want to reference between two files, say Paper1 and Paper2. I'm using hyperref in each of the documents for internal references. So as to make clear which references are internal and which are ...
user avatar
  • 1,147
0 votes
0 answers
87 views

in subfile: name{theorem.0.1} has been referenced but does not exist, replaced by a fixed one

since I was not able to find a solution online, which fixed this problem, so I hope someone here can help me :) Here is my main.tex file: \documentclass[a4paper,12pt,headsepline]{article} \...
user avatar
2 votes
1 answer
179 views

fontspec and xr package incompatible in Overleaf

I am trying to use the xr package in Overleaf and set a custom font in the referenced file. However, as soon as I load the fontspec package in the referenced file, the xr package does not recognize ...
user avatar
  • 345
0 votes
1 answer
48 views

Add a document name, while using an external document reference

I'm using xr package for referencing to external documents. I want to add external document title to a reference. How it could be obtained?
user avatar
1 vote
1 answer
58 views

Problem referencing labels with href

I am trying to reference certain sections with href in my index (not using the normal index because I wanted to make a custom one), but when clicking on them it just takes me to the top of the main ...
user avatar
1 vote
0 answers
274 views

latexmk with external references in both directions

I am aware of the question below about how to refer, in file1, to labels from file2. latexmk with external references However, I must also refer, in file2, to labels from file1. I am able to do it ...
user avatar
  • 111
3 votes
1 answer
182 views

Doc-Start appearing when using xr package

I am trying to write up an article that uses the xr package (or maybe it needs to be zref) to reference labels in two different documents: an article and a beamer presentation. The references from ...
user avatar
0 votes
0 answers
90 views

Re-calling/re-printing a theorem from an external document [duplicate]

For a manuscript I need to include theorem proofs as supplementary material. So I mention the theorem in the main file and I need to re-print the theorem in the supplementary material with the same ...
user avatar
  • 381
0 votes
1 answer
127 views

Incompatibility between xr-hyper and redefinition of \section

This is main.tex \documentclass[headings=optiontohead]{scrbook} \usepackage{subfiles, xparse, xr-hyper, hyperref} \externaldocument{main} % so that cross-references work in subfiles \let\oldsection\...
user avatar
  • 11.3k
-1 votes
1 answer
507 views

How to use \ref to refer to a \label in another document?

I have two documents and am trying to use the package xr to create a reference, in the second document, to a \label in the first. But ?? appears in the PDF instead. How do I enable the second to see ...
user avatar
  • 390
1 vote
1 answer
118 views

xr-hyper package and \includegraphics

With the two following documents, I get a correct result: in the second document, the first chapter page from first document is included and the external link opens the correct page in the first ...
user avatar
  • 67.8k
2 votes
0 answers
138 views

Trick/Workaround for cross reference between files without xr

I have a main manuscript and a supplementary materials tex files. These are based on templates by the AGU journals, therefore it is not recommended to add any other packages, than those provided. I ...
user avatar
  • 121
0 votes
0 answers
103 views

Using xr-hyper with Bibliography

Is there a way in xr-hyper to use \cite{<ref1>} in order to reference to the bibliography of the source file?
user avatar
  • 579
2 votes
1 answer
84 views

Want naked links across files

I compile via pdflatex f01.tex. My preamble normally contains ... \usepackage{xr-hyper} \usepackage{hyperref} Suppose that I have f01.tex and f02.tex in the same directory, and (for example) f01....
user avatar