MATLAB: How to log the commands executed when a link is clicked in the MATLAB Command Window so that they appear in the Command History

MATLAB

I can display a link in the Command Window as follows:
disp('Show me the <a href="matlab:dir">files</a> in this folder.');
However, when I click on the link, the command that is executed is not logged in the Command History window.

Best Answer

The ability to log the command executed by a link in the Command History window is not available in MATLAB 7.9 (R2009b).
To work around this issue, download the attached files and create a link as follows:
linkwithhistory('Show me the ', 'dir', 'files', ' in this folder.');