I, too, experienced the same problems despite changing the appropriate settings in Preferences for MATLAB R2018a on Ubuntu 18.04. The problem was fixed for me by using the -useStartupFolderPref flag as mentioned above. For future reference, my working Ubuntu .desktop launcher file now reads:
[Desktop Entry]
Type=Application
Icon=/usr/share/icons/matlab.png
Name=MATLAB R2018a
Comment=Start MATLAB
Exec=matlab -desktop -useStartupFolderPref
Categories=Development;
StartupNotify=true
StartupWMClass=MATLAB R2018a - academic use
The "StartupWMClass" line fixes the potential presence of many instances of MATLAB open in the dock.
6 Comments
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_447233
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_447233
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_447367
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_447367
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_453973
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_453973
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_473994
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_473994
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_558092
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_558092
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_812753
Direct link to this comment
https://fr.mathworks.com/matlabcentral/answers/336249-initial-working-folder-not-working#comment_812753
Sign in to comment.