Thanks for the effort, but that did not solve it sadly.
Let me explain some more. I am working with subfiles, so I have a main file Report.tex:
Code: Select all
\usepackage{Huge list of packages}
\usepackage{cleveref}
\crefname{equation}{equation}{equations}
\crefname{figure}{figure}{figures}
\crefname{section}{section}{sections}
\begin{document}
\begin{titlepage}
here i define my preferences for my titlepage
\\
\end{titlepage}
\begin{abstract}
where the abstract will go
\end{abstract}
\tableofcontents
\subfile{Theory/Theory.tex
\subfile{Methodology/Methodology.tex}
\bibliographystyle{ieeetr}
\bibliography{References/Bibliography.bib}
\appendix
\subfile{Appendix/AppendixA.tex}
\end{document}
And then I have multiple subfiles in the according folders, which works fine. Then in each of the folders I have:
Code: Select all
\documentclass[../Report.tex]{subfiles}
\graphicspath{{Methodology/}}
\begin{document}
\chapter{Methodology}\label{chap:Methodology}
\section{Pulsed Laser Deposition}\label{sec:meth PLD}
\section{X-Ray Diffraction}\label{sec:meth XRD}
\begin{equation}
\label{eq:XRD Bragg}
n\lambda=2d\sin(\theta)
\end{equation}
\cref{eq:XRD Bragg}
\section{X-Ray Reflectivity}\label{sec:meth XRR}
Bunch of text, as can be seen in \cref{fig:XRR Reflection}.
\begin{figure}[h!]
\centering
\includegraphics[width=0.8\textwidth]{Reflection.pdf}\label{fig:XRR Reflection}
\label{fig:XRR Reflection}
\caption{Reflection and refraction of X-rays on material surface.}
\end{figure}
\end{document}
In which the figure works, the equation works, the caption at the figure works, the reference to the equation says "equation (2.1)",, so that all works fine. The reference to the figure however, says "section 2.3" (this is if I run Report.tex, if I run Methodology.tex, it will give 1.something of course). I hope this makes it clearer and someone might me able to help.