move file to folder
14 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
ahmed ashiry
am 9 Mär. 2015
Kommentiert: Jan
am 23 Jan. 2018
i want function to move file on any dir in my pc to folder at any dir in my pc
0 Kommentare
Akzeptierte Antwort
Radha Krishna Maddukuri
am 9 Mär. 2015
Hi Ahmed,
movefile('source','destination')
moves the file or folder named source to the location destination, where source and destination are the absolute or relative paths for the folder or file.
For further information regarding this command, please visit the following documentation page.
3 Kommentare
Nathaniel Werner
am 23 Jan. 2018
Bearbeitet: Nathaniel Werner
am 23 Jan. 2018
I am trying to do something similar. My code is
movefile filename folderNew
but I get the following error...
Error using movefile
No matching files were found.
I've checked and the file with name 'filename' is in my current folder.
Jan
am 23 Jan. 2018
@Nathaniel Werner: Do you really want to move the file called 'filename' to a folder called 'folderNew' or are they file names? The non-functional form of commands can be confusing. Prefer the functional form with parentheses:
movefile(filename, folderNew)
% Or
movefile('FileName.txt', 'NameOfNewFolder')
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu File Operations finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!