Oct 25, 2004 #1 Kait Automotive Joined Oct 25, 2004 Messages 1 Location DE Hi, i would like to read filenames from an directory in an array so that i can loop over the array, open a file in the array, process it and save it and so on. How can i read all filenames of an directory in an array?? Thanks Kai
Hi, i would like to read filenames from an directory in an array so that i can loop over the array, open a file in the array, process it and save it and so on. How can i read all filenames of an directory in an array?? Thanks Kai
Oct 26, 2004 #2 JockeK Electrical Joined May 26, 2003 Messages 62 Location SE Read the contents of a directory using the dir command. Code: d = dir('*.dat'); Loop through the files and process them Code: for indx=1:lenght(d) process( d(indx).name ) % your processing function here end Upvote 0 Downvote
Read the contents of a directory using the dir command. Code: d = dir('*.dat'); Loop through the files and process them Code: for indx=1:lenght(d) process( d(indx).name ) % your processing function here end