This can mean, that the file is write-protected or you do not have the permissions to write in this folder. Check this either in the file explorer of the operating system or by thefileattrib command.
This tries to create the file in thecurrent folder:
dicomwrite(I,'rice.dcm',info)
Better define the folder to write to explicitly.fullfile might be useful here.
Best Answer