How to check if an (.exe) file is installed or not?
Show older comments
Hello everyone,
I am using MATLAB R2019b on windows 10.
I am designing a GUI, i need when the user pushes the Start button, MATLAB automatically checks if "FreeFem++" program is installed on the device or not?
i read about the command:
exist launchff++.exe
But it only searches in the current folder where the GUI exists, not on all the device.
And if the program is installed, I don't know its location.
So how can i search for the file everywhere or more importantly in the control panel?
I tried:
exist 'Control Panel\Programs\Programs and Features'
but it doesn't work, apparently exist command doesn't have access to search in the control panel.
Thank you in advance.
3 Comments
Hari Krishna Ravuri
on 30 Oct 2019
I understand that, you are trying to find whether an application is installed or not using exist.
The syntax of exist is
exist name searchType
name can include a partial path, but must be one of these:
- A folder on the search path
- In a folder on the search path
- The current folder
- In the current folder.
“Control Panel\Programs\Programs and Features” is not a valid path.
Please refer https://in.mathworks.com/help/matlab/ref/system.html
Wael Wanis
on 30 Oct 2019
Wael Wanis
on 2 Nov 2019
Accepted Answer
More Answers (0)
Categories
Find more on Introduction to Installation and Licensing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!