files = matlab.apputil.getInstalledAppInfo;

appName = 'SMP_Tool_Beta_v3.2.1';

startup_file_path = '';

for k = 1:length(files)
   
    if strcmp(files(k).name, appName)
        startup_file_path = files(k).location;
    end
    
end

if strcmp(startup_file_path, '')
    errordlg('SMP-tool is not installed')
else
    addpath(genpath(startup_file_path))
    sl_refresh_customizations
end
