windows-services

Windows Service - I want to access the Membership database

It looks as though the answer to my question is here; http://stackoverflow.com/questions/727123/update-asp-net-membership-from-windows-service However I cannot get any recognition for the namespace; System.Web.Security. I try to add a reference to System.Web and I get; Could not resolve assembly "System.Web". The assembly is not in th...

Registering a Python program as a Windows Server 2003 R2 Service

Hi all, I wrote a Python script that I need to have installed on Windows Server 2003 R2, that will run when a specific directory is changed in any way (new files, deleted files, etc). I believe I need to register this as a system service, in order to listen for that, but I'm really not sure. So, my question is this: does such a script n...

C# program to remote login and change password of services

I am required to write a C# program, that, given a list of servers and services running on them, remotely logs into the servers, stops the service, changes the password associated with that service and restarts the service. I am not entirely sure if it is even possible, but I would like to believe it is. Any pointers as to where / what ...

How to detect Remote Desktop Session Host using registry ?

I need to detect if Remote Desktop Session Host is installed in windows server 2008 using registry data as part of the prerequisite checker for our product. Earlier it was known as terminal service which could be detected using the HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Terminal Server\TSEnabled key but now this key "TSEnabled" ...

Windows Service Versus Winforms / WPF desktop app

I’m currently writing a windows service that’s sole purpose in life is to poll a database and, based on the resulting information, update some other data. I wrote this as a windows service because it seemed an ideal platform. I don’t need any user interaction. However, while developing it, I’ve noticed one or two issues that make deve...

Getting Permgen space error on running Jboss 5.1.0 as a service on WIndows machine.

How to solve the above issue ? ...

Let the iPhone talk to a Windows Service

Hi, I was wondering how I can let my iPhone talk to a windows service, so for example when I press a button on the iPhone, a messagebox is shown on the windows machine. Hope somebody has some good tutorials or sample code that will get me going... Thanks in advance! ...

Custom actions in a .NET Service Installer

I am writing a Windows Service in C# in Visual Studio 2010. My service will require a registry key HKLM\system\currentcontrolset\services\myservicename\parameters. It will also require a custom event source. I can't create either of these from within the service because both of these actions require running elevated on Win7, and I don't...

Close foreground thread gracefully on windows service stop

In my windows service I create one "parent" foreground thread that in turn spawns "child" threads using ThreadPool (which means they are background) to execute tasks. What is the best way to close foreground thread gracefully on windows service stop? Here is my current implementation (stripped out of task-specific logic): public parti...

WCF Service as Windows Service woes (Windows 7)

I followed the steps here to make my existing WCF service (already working fine as console application) be Windows Service as well, on my Windows 7 machine which is also my development machine. No matter what I tried, when doing the last step of using installutil, I'm getting the following message in the command line: Exception occurred...

problem generating service/executable with py2exe

I have a python program which can either act as an executable or Windows service, depending on command-line flags (e.g., -s start would launch it as a service). I'm trying to bundle this as an exe using py2exe, which works all fine and well until I try to start the program as a service. Then, I get the classic "unable to respond" error...

Using InstallUtil to uninstall service which doesn't exist

I'm using pre and post build events of my service to uninstall and install the service. The only problem is that the first time another developer uses the pre build event it fails since the service is not yet installed. My current pre build event which uninstalls is %WinDir%\Microsoft.NET\Framework\v4.0.30319\InstallUtil /u $(TargetPa...

ensuring a windows service will run before logon

I built an application that is running as a windows service and is installed through my code. All is fine except at logon. When at the first windows xp/2003 server logon screen, I am not sure if the service is running at all. If it is, then it does work as it's not functional (the service IS USING WINPCAP so that could be an issue...

How to architect ASPX, IIS & business data that is processed / loaded once a day: DLL or Service?

Anyone have suggestions how to architect the following setup: ASPX, IIS, 100s of transactions coming through the web pages and data which changes once a day & has to be processed at start-up (would be slow to reload & calculate from the database 100 times a day) Currently we have: ASPX pages running on IIS, communicating with A window...

Difference between Window Service, WCF Service application and ASP.NET web service application?

Hi, I don't know this is a right forum for my question or not? I am new in Web Services. Today i just open VS2008 and found 3 type of SERVICE project 1. Window Service 2. WCF Service application 3. ASP.NET web service application Please help me to find out the difference between these three project? When should we decide which typ...

how to get logged in user and machine name from window service in c# ?

how to get logged in user and machine name from window service in c#. when i try Environment and other class to get logged in user name it just returns NT AUTHORITY\SYSTEM from window service. please suggest thanks arvind ...

What does "delayed start" do in startup type for a windows service?

What is the difference between Automatic and Automatic (Delayed Start) for a property setting for a windows service? i.e. what do I gain or lose by setting my service as one or the other? Running the service on Windows Server 2008 x64 ...

Where should Windows Services write Application Data?

Hi, We have a Windows Service as part of our software, this is used to transfer data to a remote database in the background even when there is no user logged into the system. Currently this data is cached in the Program Files directory, and I don't think this is a good idea because it requires us to reduce the security permissions on o...

Code within nUnit works fine but within Windows Service gets HTTP status 403: Forbidden when calling a remote Web Service

Context I'm working a c# module which is responsible to integrate our business with an external entity as part of our SOA system. The external entity provides web services. They're a throughly tested as it is a federal government product. The module has been developed using test-driven approach, we use nUnit and everything was fine durin...

Passing constants as arguments in INNO's Exec()

I have created an installer using Inno Setup in which I am executing an exe that I created to create a small service inside Windows XP. I need to pass two arguments to the exe - "-install" and the path of the installation directory. I have no way of expanding the constant {app} to pass the actual value inside of {app}. Is there some way ...