MathGroup Archive 2008

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

Search the Archive

Import syntax question

  • To: mathgroup at smc.vnet.net
  • Subject: [mg85440] Import syntax question
  • From: Mark Fisher <particlefilter at gmail.com>
  • Date: Sun, 10 Feb 2008 05:22:57 -0500 (EST)

Hi all,

I find Import wonderful but frustrating. For example, I can get
individual items such as "Author" and "Title" in separate calls:

Import["file.pdf", "Author"]
Import["file.pdf", "Title"]

but I can't get a list as in

Import["file.pdf", {"Author", "Title"}]

Instead I get an error message that say "Title" is not present (which
seems misleading at best, since I already accessed it above). Is that
syntax supposed to work or not? (Frankly, I'm having a hard time
figuring out what the proper generic syntax is for Import, especially
since there are so few examples in the documentation.)

BTW, I found out I can use

{"Author", "Title"} /. Import["file.pdf", "Rules"]

Is that what I "should" be doing? (It seems like overkill since Import
has to import a bunch more stuff that I don't want, at least in this
example.)

--Mark


  • Prev by Date: NDSolve and Parametric Plot
  • Next by Date: RE: Where to put ConvexHull3D.m
  • Previous by thread: Re: NDSolve and Parametric Plot
  • Next by thread: Re: Import syntax question