Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Starting a service on computer startup
Forum Updated to NodeBB v4.3 + New Features

Starting a service on computer startup

Scheduled Pinned Locked Moved General and Desktop
5 Posts 3 Posters 2.9k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K Offline
    K Offline
    Ketan Shah
    wrote on last edited by
    #1

    Hii,
    In my application I am writing a code that starts a particular service "for eg:- say MySql." on computer startup....Can any 1 tel me how can i do this and using which Qt class, its possible..
    please help..

    1 Reply Last reply
    0
    • Z Offline
      Z Offline
      ZapB
      wrote on last edited by
      #2

      Why do you want to do this from your application? Why not just use the platform facilities for doing this platform-specific task? For example on Gentoo I would just do:

      @
      rc-update add mysql default
      @

      Other distros have equivalents. On Windows you can use the service manager to start the service automatically.

      Nokia Certified Qt Specialist
      Interested in hearing about Qt related work

      1 Reply Last reply
      0
      • G Offline
        G Offline
        goetz
        wrote on last edited by
        #3

        And on the Mac you have LaunchAgents and LaunchDaemons.

        It is almost completely out of scope of Qt, there is no means of installing such a service with an application, that would be more a matter of an installer package, IMHO.

        http://www.catb.org/~esr/faqs/smart-questions.html

        1 Reply Last reply
        0
        • K Offline
          K Offline
          Ketan Shah
          wrote on last edited by
          #4

          I just want to add a checkbox in my application,such that on checking that checkbox the particular service should be started on windows startup and on unchecking the checkbox, the service should not start on windows startup....please help..

          1 Reply Last reply
          0
          • G Offline
            G Offline
            goetz
            wrote on last edited by
            #5

            You will have to use native Windows API for this. I'd suggest you ask in a respective forum, it's more likely you find someone with that knowledge over there.

            Oh: And do not forget do do a web search before - use your favorite search engine for that task. You know already what keywords to feed in...

            http://www.catb.org/~esr/faqs/smart-questions.html

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved