Graphics, Figures & TablesCant specify path name

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
cyrus123
Posts: 4
Joined: Sat Apr 18, 2009 3:31 am

Cant specify path name

Post by cyrus123 »

Hi all,

I'm trying to specify the pathname to pictures in my masters thesis and its not working.

\graphicspath{{'C:\Documents and Settings\Cyrus Abdollahi\Desktop\American Dynamics\Solid Works Drawings'}}
From google, it appears the problem is that it doesn't like white spaces. Is there any way around this?

Thanks!

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

Cant specify path name

Post by Stefan Kottwitz »

Hi,

try grffile,

Stefan
LaTeX.org admin
cyrus123
Posts: 4
Joined: Sat Apr 18, 2009 3:31 am

Re: Cant specify path name

Post by cyrus123 »

Thanks stefan,

How do I go about adding this package into LaTeX? I don't know how to get this to work.

Thanks,

Cyrus
User avatar
localghost
Site Moderator
Posts: 9201
Joined: Fri Feb 02, 2007 12:06 pm

Cant specify path name

Post by localghost »

Just start the package manager of your LaTeX distribution and install it. Afterwards include it like all the other packages in your preamble. If you are not sure how to do that, refer to the grffile manual. Note that this package is part of the oberdiek bundle. The package manager of your LaTeX system will offer to install this bundle.


Best regards and welcome to the board
Thorsten¹
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes[/size]

¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
cyrus123
Posts: 4
Joined: Sat Apr 18, 2009 3:31 am

Re: Cant specify path name

Post by cyrus123 »

Hi Thorsten,

Thanks for the reply. I tried doing what the manual said, but Its not working (I'm probably not doing something right).

I don't know how to install packages (I've never done it before).

This is what I put in my header of my document

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{grffile}
\usepackage{griffle}

in this order. Would you have some code that works that I could copy paste from here into my document and see if that works?
User avatar
localghost
Site Moderator
Posts: 9201
Joined: Fri Feb 02, 2007 12:06 pm

Cant specify path name

Post by localghost »

cyrus123 wrote:[...] I don't know how to install packages (I've never done it before). [...]
Please read the first sentence of my last reply once again. Refer to the documentation of your LaTeX distribution to learn how to install packages on your system.

You simply need to include the package in your preamble.

Code: Select all

\usepackage{griffle}
More lines are not necessary. For more options of the package see the manual (Section 1 - Usage, p. 2ff).
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes[/size]

¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
phi
Posts: 577
Joined: Tue Oct 21, 2008 8:10 pm

Cant specify path name

Post by phi »

Three suggestions:
  • Don't use the \graphicspath command, use explicit pash specifications in the \includegraphics command or the TEXINPUTS environment variable instead
  • Don't use absolute path names unless absolutely necessary, they make your document non-portable and dependent on an arbitrary directory layout
  • Don't use backslashes as directory separators, use forward slashes instead
Post Reply