Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2000
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2000

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

Search the Archive

Re: checking for presence of files

  • To: mathgroup at smc.vnet.net
  • Subject: [mg24495] Re: checking for presence of files
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Thu, 20 Jul 2000 03:01:38 -0400 (EDT)
  • Organization: Universitaet Leipzig
  • References: <8l3f5d$ksj@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,

you can search the $Path variable and some subdirectories.

The call below search for a file MGLWelcome.nb in all
directories in the 

APathDirectory/MathGL3d/Documentation/English


Select[FileNames["*MGLWelcome.nb", Join[(ToFileName[
              {#, "MathGL3d", "Documentation", 
                "English"}] & /@ $Path), $Path]], # =!= {} &]

and return a list of all matches. It is typical not wise
to search the full harddisk. 

Regards
  Jens


Otto Linsuain wrote:
> 
>  Hi all. I know the answer to this could be system-dependent. I work
> with Mathematica 4.0 on unix workstations.
> 
>  I wonder if it is possible to define a function that checks if a file
> exists in your disk, something like
> 
>  FindFile[filename_String] = True if the file exists, False otherwise.
> 
>  Any ideas would be appreciated. Otto Linsuain.


  • Prev by Date: more wrong integrals
  • Next by Date: Re: 12-bit Tiffs importable?
  • Previous by thread: Re: checking for presence of files
  • Next by thread: Looking for examples of instrument i/o via MathLink