Contents Previous Next Subchapters

Listing A Directory And All Its Subdirectories
Syntax listdirs(dir)
See Also listdir , lenfile , rmdir , mkdir

Returns a character matrix containing a listing of the directory specified by dir, including all of its files and subdirectories, where dir is a character row vector. The first 10 columns of the return value contain the length in bytes for each file, but are blank for listings of directory names.

Directly below each directory, its files appear sorted alphabetically. The subdirectories then appear, sorted alphabetically.

If O-Matrix is installed in C:\OMWIN, and you enter
O-Matrix will reply
     69120     c:\omwin\dll\FTP.DLL          
     126464    c:\omwin\dll\MATFILE.DLL      
     61440     c:\omwin\dll\SAMPLE.DLL       
     129536    c:\omwin\dll\TECPLOT.DLL      
     10394     c:\omwin\dll\SRC\BREAD.CPP    
     1421      c:\omwin\dll\SRC\BTEST.CPP    
     9937      c:\omwin\dll\SRC\BWRITE.CPP   
     5728      c:\omwin\dll\SRC\DLL.H        
     2736      c:\omwin\dll\SRC\DLL.HPP      
     135       c:\omwin\dll\SRC\GET.BAT      
     4655      c:\omwin\dll\SRC\MATRIX.H     
     5004      c:\omwin\dll\SRC\MYCOLMAX.CPP 
     5012      c:\omwin\dll\SRC\MYROWMAX.CPP 
     3979      c:\omwin\dll\SRC\VC\VC.DSP    
     527       c:\omwin\dll\SRC\VC\VC.DSW    
     2161      c:\omwin\dll\SRC\VC\VC.PLG    
     50176     c:\omwin\dll\SRC\VC\VC.ncb    
     48640     c:\omwin\dll\SRC\VC\VC.opt