One of the tools I use at work is Matlab, however due to server license there is limited number of users that can use it at the same time.
I decided to write a short script that will open Matlab - simple script with a infinite loop. Now I want to improve my code a bit, to determine if the Matlab is actually opened (otherwise Licence error pops up).
Easy way would be just to check the process in task manager - unfortunately if error occurs as Matlab.exe process (the same as I would be in case of properly opened program).
So I figured out maybe it would be possible to check the name of the window header to determine if there is error or no. I tried to find some solution on the internet, with no luck. Could You provide me with some hint? Or maybe some other solution to the problem?
You can check with
$MATLABROOT/etc/lmstat -c yourlicencefile -a
and parse its output to see if you allocated a license or not to your computer.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.