Results 1 to 4 of 4

Thread: install qtservice program on windows 7x64 VS2013

  1. #1
    Join Date
    Mar 2014
    Location
    USA
    Posts
    85
    Thanks
    17
    Thanked 2 Times in 2 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default install qtservice program on windows 7x64 VS2013

    I created a program using qtservice called User Log Service. I can't figure out how to install the service onto the computer. I'm pretty sure I've built it right, but without installing it I can't test it. From what I've read you can't run a service in debug mode. I've never done this before. I looked online and the only thing I can find is to use InstallUtil in admin command line. I tried running InstallUtil from windows but I get System.BadImageFormat exception: could not load file "...\UserLogService.exe" or one of its dependencies. The module was expected to contain an assembly manifest. It's a very simple program with just your very basic libraries.

  2. #2
    Join Date
    Mar 2008
    Location
    Kraków, Poland
    Posts
    1,536
    Thanked 284 Times in 279 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: install qtservice program on windows 7x64 VS2013

    QtService application can be run with parameters. Run it on the command line with the -h parameter.
    For debugging run it with -e parameter.

  3. #3
    Join Date
    Mar 2014
    Location
    USA
    Posts
    85
    Thanks
    17
    Thanked 2 Times in 2 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: install qtservice program on windows 7x64 VS2013

    I tried using -h nothing happened. I used -e and it runs. I guess I'm going to find something that explains how to debug from the command line. Only it runs as the process "User Log Service.exe" and application "User Log" (the program the service runs). Nothing shows up in services. What I need to have happen is for the program to run as a process that initiates on start up. Only admin can start/stop/pause etc. the process, and the user can use the program for logging off and on, and isn't in the list of programs or processes in Windows Task Manager (so that the user can't quit it). There's a lot of processes like that so I know there's a way to do it, but maybe I'm being unfair and asking for too much asking it on a forum. I would need it spelled out for me pretty clearly and that takes a lot of time from the expert poster.

  4. #4
    Join Date
    Mar 2008
    Location
    Kraków, Poland
    Posts
    1,536
    Thanked 284 Times in 279 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: install qtservice program on windows 7x64 VS2013

    Parameter -h :
    Qt Code:
    1. NameOfYoursService.exe -[i|u|e|s|v|h]
    2. -i(nstall) [account] [password] : Install the service, optionally using given account and password
    3. -u(ninstall) : Uninstall the service.
    4. -e(xec) : Run as a regular application. Useful for debugging.
    5. -t(erminate) : Stop the service.
    6. -c(ommand) num : Send command code num to the service.
    7. -v(ersion) : Print version and status information.
    8. -h(elp) : Show this help
    9. No arguments : Start the service.
    To copy to clipboard, switch view to plain text mode 

Similar Threads

  1. problems installing qtservice windows 7 Qt 5.4.1
    By TonyInSoMD in forum Installation and Deployment
    Replies: 4
    Last Post: 16th February 2018, 21:42
  2. Trying to install QtService examples in windows 7
    By nikhilqt in forum Qt Programming
    Replies: 2
    Last Post: 15th January 2012, 04:28
  3. QtService Library (dll) for windows
    By ruben.rodrigues in forum Installation and Deployment
    Replies: 1
    Last Post: 22nd October 2010, 20:18
  4. Replies: 1
    Last Post: 30th April 2010, 14:25
  5. QtService on Windows as Non-Interactive
    By stefanadelbert in forum Qt Programming
    Replies: 2
    Last Post: 26th April 2010, 04:27

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.