Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive

MathGroup Archive 2007

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

Search the Archive

Re: forming filename string

  • To: mathgroup at
  • Subject: [mg84057] Re: forming filename string
  • From: Jens-Peer Kuska <kuska at>
  • Date: Fri, 7 Dec 2007 06:57:17 -0500 (EST)
  • Organization: Uni Leipzig
  • References: <fjavqr$ru4$>
  • Reply-to: kuska at


you should increase the number of backslashes -- only
will be a single valid backslash ;-)

or may


help ??
man_koshi wrote:
> Hi, I am new to mathematica, and I just wanted to Import some of .nb files into it, and then export it into different format. I can do it one by one, but I want to form varying 'filename'. Can you check what's wrong with it.
> Do[infile=StringForm["\"U:\\\\data\\\\file``.nb\"",i]; outfile=StringForm["\"U:\\\\datao\\\\file``.tex\"",i]; x=Import[infile];Export[outfile,x];,{i,0,10,1}]
> I am getting errors like:
> Import::chtype: First argument "U:\\data\\file0.nb"
>      is not a valid file, directory, or URL specification.
> Export::chtype: First argument "U:\\datao\\file0.tex" is not a valid file specification.
> Import["U:\\data\\file0.nb"] it works! so is not an invalid file address. I guess there is some requirement for filename string??
> Please help.

  • Prev by Date: Re: Contour Lines colored by temperature scale
  • Next by Date: Re: Re: Re: Mathematica: Long divison for polynomials
  • Previous by thread: forming filename string
  • Next by thread: Re: Tally[ ] and Union[ ]