Link to home
Start Free TrialLog in
Avatar of mrxz
mrxz

asked on

Transforming a notifing program in a NT Service

Hi everyone!

I´m Administrator of my Company and I had to make a program that notify any change in a folder.
The answer that I acceppted from you were:

http://www.mvps.org/vbnet/code/shell/shchangenotify.htm

Now I have to change this program to a NT Service (It MUST RUN ALL THE TIME whenever an user is logged or not).

Thanks for any help!!!

Regards,
mrxz
Avatar of TimCottee
TimCottee
Flag of United Kingdom of Great Britain and Northern Ireland image

Use the NT Reskit tool SC.Exe to install this as a service on a machine.
Or check out these links which describe how to do this in more detail. One with an activex control, the other using srvany.exe.

http://msdn.microsoft.com/library/techart/msdn_ntsrvocx.htm
http://vbwire.com/advanced/howto/service.asp 
Avatar of Guy Hengel [angelIII / a3]
what i used is the NTService control (NTSVC.OCX) from m$. This lets you react on the events (Start, Stop, Pause, Continue), whereas the tool SC.exe simulates this.

if you need the file and could not find it at m$ site, i can send it to you.

CHeers

to be honest, i think i remember that the ShellNotify+NTService does not seem to work as long as there is not explorer open (for the user/session).
i think a collegue in my company tried this already with no success.
i didn't try it yet, but you might try to open an explicit explorer (using shell) in your application.

Hope this helps
Avatar of mrxz
mrxz

ASKER

Hi TimCottee!

Can you tell me more about the NT Reskit tool SC.Exe?
Can you tell me some steps to do it?

Regards,
mrxz
Avatar of mrxz

ASKER

Hi, everyone!!!

I looked at http://vbwire.com/advanced/howto/service.asp 

When I tried to use SC.EXE from Resource kit, it installs and when starts it brings a message like "Could not start, service timeout" with or without NTSVR.OCX  

When install using NTSVR.OCX   it didn´t work  even calling explorer.exe

What should I do?

Regards,
mrxz

This question appears to have been abandoned. A question regarding will be left in the Community Support area regarding its disposition; if you have any comment about the question, please leave it here.

Unless there is objection or further activity, one of the moderators will be asked to refund the points and move the question to the PAQ.

The link to the Community Support area is:
https://www.experts-exchange.com/jsp/qList.jsp?ta=commspt

DO NOT ACCEPT THIS COMMENT AS AN ANSWER.

Regards,

ep
Avatar of mrxz

ASKER

Hi!
I had not have any suitable answer for this question, so I decied to delete it.

Regards,
Mrxz
mrxz,

There is some valuable information here, even if it didn't resolve your issue; as such, I've recommended that your points be refunded, and that the question be moved to the Previously Asked Questions.

You might want to repost it (if it is still an issue) so it will be nearer the top of the list. This will also give you the opportunity to update the information.

Regards,

ep
ASKER CERTIFIED SOLUTION
Avatar of ComTech
ComTech

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial