http://imagej.273.s1.nabble.com/Recursive-processing-of-a-directory-not-working-correctly-tp5007797p5007823.html
processing folders recursively. You can open it in the script editor via
'Templates > Macros > Process Folder'.
> to check whether this is a directory.
> Hi Matt,
>
> you can put square brackets around the directory+filename, then spaces don't do any harm.
>
> run("Bio-Formats Windowless Importer", "open=["+inBase + path+"] color_mode=Default view=Hyperstack stack_order=XYCZT");
>
> If you have
> open=C:\Users\Matt Jacobs\Desktop\K259_tlx3cre_Rabies\whateverFile.vsi
> the space is taken as a delimiter,
> open=C:\Users\Matt
> and the next statement would be
> Jacobs\Desktop\K259_tlx3cre_Rabies\whateverFile.vsi
> As the second part is not any keyword, it is probably ignored.
> So it should be
> open=[C:\Users\Matt Jacobs\Desktop\K259_tlx3cre_Rabies\whateverFile.vsi]
>
> ---
>
> One more point:
> in your macro, you have
> if (endsWith(path, "/"))
> to check whether this is a directory.
> It would be better to use
> if(File.isDirectory(path))
> The current code seems to work also under Windows because ImageJ replaces the backslash by a slash, but relying on this is not a nice solution.
>
> Michael
> ________________________________________________________________
> On May 20, 2014, at 22:42, matsojr22 wrote:
>
>> Let me also clarify that I am currently testing the macro on files I have
>> copied to the desktop...
>>
>> Input directory is C:\Users\Matt Jacobs\Desktop\K259_tlx3cre_Rabies\
>> Output directory is C:\Users\Matt Jacobs\Desktop\fiji output\
>>
>> Also, I'm just recognizing that the error is not telling me that
>> "C:\Users\Matt Jacobs\" does not exist... it is telling me the file
>> "C:\Users\Matt" does not exist...
>>
>> Am I having trouble just because I have spaces in the directory?
>>
>> Thanks again,
>> Matt
>>
>>
>>
>> --
>> View this message in context:
http://imagej.1557.x6.nabble.com/Recursive-processing-of-a-directory-not-working-correctly-tp5007797p5007811.html>> Sent from the ImageJ mailing list archive at Nabble.com.
>>
>> --
>> ImageJ mailing list:
http://imagej.nih.gov/ij/list.html>
> --
> ImageJ mailing list:
http://imagej.nih.gov/ij/list.html>