windows - Is there any reason why a Win Service would not execute functions in an external library? -


i new writing windows services strange me. have debugged external library using winform. external library drive mapping, copying directory structure, deleting original directory, renaming copied directory, , removes mappings.

so, when write service initialize external class , start process, service doesn't seem doing think should doing. appears doing nothing , ignoring going on.

is there missing? external library need have security attributes?

update found out how attach debugger, per @will's comment: system.diagnostics.debugger.break()

edit
helps when copy app.config file correct directory!!!

not lot go on here. first, can debug service, should doing rather using winform frontend test code.

the issue either service not created properly, or you've got security issue.

your service receive start message, after must run own code, on different thread (a timer common way this).

if service touching drive, user account under executes must have rights perform operations attempts. try changing user account under executes own , see if starts working.


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -