Removing rows from MyFolderInfo = dir('myfolder') before specific date
    3 vues (au cours des 30 derniers jours)
  
       Afficher commentaires plus anciens
    
    Ulrik William Nash
 le 18 Août 2017
  
    
    
    
    
    Réponse apportée : Adam
      
      
 le 18 Août 2017
            Having applied the code:
MyFolderInfo = dir('myfolder') ;
and having thus created the struct "MyFolderInfo" with 5 fields containing information about the content of my directory, I now want to update the list. In particular, I wish to remove from "MyFolderInfo" all rows for the files that were updated before a specific date.
How is this done?
0 commentaires
Réponse acceptée
  Adam
      
      
 le 18 Août 2017
        myDate = '10-Jul-2015';
myDateNum = datenum( myDate );
MyFolderInfo( [ MyFolderInfo.datenum ] < myDateNum ) = [];
0 commentaires
Plus de réponses (0)
Voir également
Catégories
				En savoir plus sur Dates and Time dans Help Center et File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

