FindFile for more than one filetype [message #28582] |
Thu, 20 December 2001 12:26 |
sargum_manley
Messages: 2 Registered: December 2001
|
Junior Member |
|
|
Hello,
I have a folder full of *_average.int files where the * represents
different years (1981-2000).
I am trying to make it so that my variable, filelist, equals two
files: (1)1981_average.int and (2)1982_average.int and then the next
time, filelist equals: (1)1982_average.int and (2)1983_average.int and
so on. It is also important that I get the filecount to equal 2.
However, I can not figure out how to do it using the FindFile function
using the IDL language.
This is what I have so far...(of course there is other stuff in btwn)
for yr = 1981, 2000 do begin
filelist = FINDFILE(outpath + string(yr, FORMAT = '(I4.4)')
+ '*'+ '_average.int', COUNT=filecount)
and
FINDFILE(outpath + string(yr+1, FORMAT = '(I4.4)')+ '*'
+ '_average.int', COUNT=filecount)
endfor
trying to use the "AND" here gives me an error about how strings can
not be used in this way or something but I left the code up here so
that the concept of what I want to achieve is clear.
Thanks.
Sue
|
|
|