MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: notebook directory

  • To: mathgroup at smc.vnet.net
  • Subject: [mg61670] Re: [mg61666] notebook directory
  • From: Jeff Bryant <jeffb at wolfram.com>
  • Date: Tue, 25 Oct 2005 01:28:04 -0400 (EDT)
  • References: <200510250107.VAA16884@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

   You can use the following to specify that the working directory is 
the same as your saved notebook:

SetDirectory[ToFileName[("FileName"/.NotebookInformation[EvaluationNotebook[]])[[1]]]];

I use this all the time to set the working directory to the same 
directory as the notebook I'm working in.

-Jeff

Hannes Kessler wrote:
> Dear mathematica-experts,
> 
> its a typical situation that I want to analyze some data files in the
> same directory where the mathematica-notebook is located.
> Is there a possibility to open the notebook and set the current working
> directory in a different way than issuing a manual
> SetDirectory["...\specific_directory"] command?
> 
> Ideally, there should be some something like a state variable
> $NotebookDirectory one could refer to.
> 
> Best regards,
> Hannes Kessler


  • Prev by Date: Re: Complex numbers in Mathematica
  • Next by Date: Re: notebook directory
  • Previous by thread: notebook directory
  • Next by thread: Re: notebook directory