Searching files
38 次查看(过去 30 天)
显示 更早的评论
Is it possible to search the file in the matlab using matlab codes? Plz respond...
1 个评论
Jan
2012-4-22
Please add the necessary details: Are you looking for a file name, or a specific contents of a file?
采纳的回答
Junaid
2012-4-22
yes it is possible to search files.
you can write code as you like. For example I want to search file 'test.txt' in current folder c:/matlab/ then I can do like this.
files = dir('c:/matlab/*.txt');
now files contains all files with txt format. now you can loop for your file.
there are many other ways. This is just example to show you.
0 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 File Operations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!