To follow up with "Diary file with current date and time as time stamp,"
% Turn On Diary Logging
diary off % first turn off diary, so as not to log this script
diary_filename=['PVUPAMain',datestr(now,30)];% setup temp variable with filename + timestamp, echo off
set(0,'DiaryFile',diary_filename)% set the objectproperty DiaryFile of hObject 0 to the temp variable filename
clear diary_filename% clean up temp variable
diary on% turn on diary logging
I would like to define a path to the file. For example, suppose we want to have a file under "C:\" Please advise the next step.
Best Answer