views:

81

answers:

3

A windows service written in c# which actually interacts with MS Word works fine when run in debug mode..or running it from the command prompt..

But it's not working after installing it as a service. The account which runs the service is an Administrator (local).

Server 2008 R2...never had a problem before using in 2003

+2  A: 

The best way to understand "why my service is not running?" is using

            try
            {

            }
            catch (Exception ex)
            {
                EventLog.WriteEntry(ex.Message + ex.StackTrace);
            }

in On Start, Your Main Method, etc.. event.

Serkan Hekimoglu
A: 

Does the service account have "Log on as a service" rights?

Noel Abrahams
yes..it does...that where I set Admin(local) account to run the service
Mike
A: 

Exception has been thrown by the target of an invocation. at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams) at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args)

Mike