Solved

Unable to execute external GUI program from Windows service

Posted on 2008-10-28
1
713 Views
Last Modified: 2009-07-29
Hi,
I have a Java server application that should run on a remote computer and receive control messages from a client. When the message is received, server should execute an external command like opening a notepad. In general the application is used for testing and all GUI operations will be done through the Autoit3 application.
I have converted my server application into a windows service using Java Service Wrapper by http://wrapper.tanukisoftware.org.
After running successfully the service I can communicate with it from the remote client, the commands are being executed but all GUI related operations (like opening notepad) are not happening. When I am running this on a local machine everything works fine. The machine that runs the server is logged using user that has administrator rights. For the windows service I have set the "allow service to interact with desktop" option, so this is not the problem here.

--
Thanks in advance for the help
0
Comment
Question by:aquasw
1 Comment
 
LVL 3

Accepted Solution

by:
caylt earned 500 total points
ID: 22987263
Hello,

By default, services use a noninteractive window station and cannot interact with the user. However, an interactive service can display a user interface and receive user input.

These need to be set up slightly differently:

Interactive Services: http://msdn.microsoft.com/en-us/library/ms683502(VS.85).aspx

Note that Microsoft warns against running Interactive Services in an elevated security context, such as the LocalSystem account.
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Skype is a P2P (Peer to Peer) instant messaging and VOIP (Voice over IP) service – as well as a whole lot more.
Developer portfolios can be a bit of an enigma—how do you present yourself to employers without burying them in lines of code?  A modern portfolio is more than just work samples, it’s also a statement of how you work.
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question