[Solved] Only one instance of application
-
How can I make it that the user can only run one instance of my application at a time?
Thanks in advance.
-
Hi,
you can use "QtSingleApplication":http://qt.nokia.com/products/appdev/add-on-products/catalog/4/Utilities/qtsingleapplication/, a class supplied by Qt Solutions Catalog.
Tony.
-
[quote author="Antonio Di Monaco" date="1288976186"]Hi,
you can use "QtSingleApplication":http://qt.nokia.com/products/appdev/add-on-products/catalog/4/Utilities/qtsingleapplication/, a class supplied by Qt Solutions Catalog.
Tony.[/quote]
Thanks for the help!
-
Also if your app is simple and don't want any new command line arguments
Simple use QProcess to check process exits or not
if yes say stop running the app.Obviously QtSingleApplication is good solution but not for simple apps.