I had written a small monitoring program for Windows 98 and have started to convert it into a service for NT.
So far it looks good, i've used a template from http://www.jgsoftware.com/nt.htm
-> the vpcsrvce.zip and the service installs, accesses all my modules and functions from the form and everything is great...until... i use the FindWindow command.
For some reason it just wont work when being used as part of a service. It just seems to return 0 always.
If you download the zip file above and replace the timer procedure 'beep' command with...
h:= Findwindow (nil,'Registry Editor');
if h <> 0 then beep;
what would work as a program, seems to not work in the service form. Any ways to get around this problem... do i have to change one of the lines of code in the service procedures included?
I have already tested the equivalent program on NT and it runs fine, but i need it to run as a service, and i would preferably keep the template above as it is easy apart from this one small problem.
Thanks for your help.