# Error message: I can't find the file

I have tried to compile the following file in three different directories. There is only one command line to be printed! I get this error message.

This is pdfTeX, Version 3.14159265-2.6-1.40.17 (MiKTeX 2.9 64-bit) entering extended mode
! I can't find the file C:/Users/Owner/Desktop/File for Calculus Course/Calculus I - AP Test, Version 1 (Solutions).tex"'
<*> ... us I - AP Test, Version 1 (Solutions).tex"
Please type another input file name:


Here is the file.

\documentclass{amsart}
\usepackage{mathtools}

\usepackage{tikz}
\usetikzlibrary{calc,intersections}

\usepackage{pgfplots}
\usepgfplotslibrary{polar}
\pgfplotsset{compat=1.11}

\begin{document}

\centerline{\textbf{\Huge{Solutions to AP Calculus Test}}}

\end{document}

• Did nobody teach you that spaces and special characters in file names (and directory names) are to be avoided at all times? – Johannes_B May 7 '17 at 13:12
• \centerline{\textbf{\Huge{Solutions to AP Calculus Test}}}` Seems you want to make a title. You are lucky that this works, but you shouldn't use that code. – Johannes_B May 7 '17 at 13:13
• @Johannes_B This file compiled just fine for me until my last edit. I must have edited this file fifty times! I saved a copy of the file under a different name - a name containing a space - and it compiled. I also have a file called "Calculus I - AP Test, Version 2 (Solutions)" and that compiles fine. Actually, I have hundreds of files with names that have spaces and hypens! They all compile. – user74973 May 8 '17 at 14:22