Hi all i am a noob to programming (in practice) have done some courses though, and i apologise in advance if i am wasting your time with my problem.
I would like to process images using a batch file that i have made already, the problem is i need to process 100+ images using their file name as an input and would like to know how to make this possible?
my script looks like this
@echo on
echo file name convention:M02-ASCA-ASCSMR02-NA-3.2-20140129081200.000000000Z-1095218.bfr
echo test from UMARF
echo note orbit number as %9
rem set orbitnumber=%9
set longfilename= %filename%
rem: shorfilename1=yyyymmdd
set shortfilename1=%longfilename:~26,12%
echo shortfilename1
pause
set PATH=%D:\geonetcast\Software\ILWIS\Ilwis372_oct2012\Extensions\GEONETCast-Toolbox\util%
call 7z.exe e %longfilename%.bz2
pause
echo on
set PATH=%D:\geonetcast\Software\ILWIS\Ilwis372_oct2012\Extensions\GEONETCast-Toolbox\util%
pause
rem: Ascat surface soil moisture
rem: in top 5 cm of soil
rem: output point map is estimate of water saturation from 0-100%
set VBUFR_TABLE_DIR=D:\geonetcast\Software\ILWIS\Ilwis372_oct2012\Extensions\GEONETCast-Toolbox\util\tables
set VBUFR_DATA_DIR=D:\test
call bufrtool.exe pick %longfilename% 6001 5001 40001 40002 40003 40007 > D:\test\%shortfilename1%_org.txt
call deletelines.exe D:\test\%shortfilename1%_org.txt D:\test\%shortfilename1%_imp.txt 7
copy D:\geonetcast\Software\ILWIS\Ilwis372_oct2012\Extensions\GEONETCast-Toolbox\util\asc.dm#
copy D:\geonetcast\Software\ILWIS\Ilwis372_oct2012\Extensions\GEONETCast-Toolbox\util\asc.dom %shortfilename1%.dom
set PATH=%D:\geonetcast\Software\ILWIS\Ilwis372_oct2012%
call ilwis.exe -C D:\test\%shortfilename1%.tbt:=table(D:\test\%shortfilename1%_imp.txt,Space,Convert,none,ID(D:\test\%shortfilename1%.dom{id}),X(value.dom{-180:180:0.00001}),Y(value.dom{-90:90:0.00001}),SM_perc(value.dom{0:100:0.01}),Error_perc(value.dom{0:100:0.01}),Mean_SM(value.dom{0:100:0.0001}),Quality(value.dom{0:100:1}));
call ilwis.exe -C D:\test\%shortfilename1%_smperc.mpp:=PointMapFromTable(D:\test\%shortfilename1%,LatlonWGS84,SM_perc);
rem
end
(i know a tad long)- i have searched for a solution i can use but am struggling at present, I found this code on another site but can't get it to work for my itteration,
FileList = dir('*.csv');
N = size(FileList,1);
for k = 1:N
% get the file name:
filename = FileList(k).name
disp(filename);
% insert your script code here
would really appreciate some help.
Regards J-bon3