Why am I unable to copy to root directories of drives when using the COPYFILE function in MATLAB 7.0.1 (R14SP1)?
3 次查看(过去 30 天)
显示 更早的评论
When using non-English language settings in Windows, the COPYFILE function returns errors when attempting to write to "root" Windows directories such as A:\ and C:\. For example, the following command:
[status,message,messageid]=copyfile('a.mat','C:\a.mat','f')
Results in the the following contents of status and messageid:
status =
0
messageid =
MATLAB:COPYFILE:OSError
采纳的回答
MathWorks Support Team
2009-6-27
This bug has been fixed in Release 14 Service Pack 2 (R14SP2). For previous releases, read below for any possible workarounds:
There is a bug in MATLAB 7.0.1 (R14SP1) that affects the way the COPYFILE function handles copying to "root" Windows directories on machines with non-English language settings. To work around this issue, you can use the DOS Copy command within MATLAB to copy files to "root" Windows directories as follows.
dos('copy a.mat C:\a.mat');
0 个评论
更多回答(0 个)
另请参阅
类别
在 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!