Link to home
Start Free TrialLog in
Avatar of Smiley2003
Smiley2003

asked on

Program Run As Service "SYSTEM"

Hey everyone, I am working on a program for an Internet Cafe. I want the program to be able to run as a Service under Windows. I would like the service's "User Name" to run as "SYSTEM" instead of the current logged on user. I have tried modifying the registry values but I have failed miserably; not to mention the program ends after about 30 seconds of starting Windows. The method/answer posted here should be practical for installation of my program. If possible, I would also like to make the program uncloseable, like certain Norton programs (NPROTECT.exe). When ending this Norton application, it gives the error "The operation could not be completed. Access is denied." Or... something like various Windows components (Example: csrss.exe) which say "This is a critical system process. Task Manager cannot end this process."

Thanks for the help, I will accept either of those two types of answers, (Unclosable Task) or (SYSTEM Service).

Cheers,
Chuckie Ice
Avatar of mugman21
mugman21

Honestly,

I think you would be better off creating the service using Real Basic (from realsoftware.com). Real Basic is very very simular to Visual basic, except it can produce different project types (and also for multiple OS's). Visual Basic alone is not an apporpriate language to create services with. There are several work-arounds out there, but none are robust enough.


If you don't wana use Real Basic, borland's Delphi also can create decent service apps..

Mugman
I concur with mugman21 in this case. VB6 is not appropriate to create services. You may be able to arrange it to get it running, but I do not recommend it in any case.

Instead of VB6 you could also use .net (VB.NET or C#) to create your service application, which is a relatively easy task there.

Zamba
Avatar of Smiley2003

ASKER

Hey mugman and Zamba, thanks for the suggestions. However, since I have already designed and just about fully completed this project, is there any *work-arounds* that anyone knows of? I suppose if there isn't, I could go back and redo the project in another language, but thats not my current mindset yet.

Cheers,
Chuckie Ice
ASKER CERTIFIED SOLUTION
Avatar of Zamba1
Zamba1

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
Smiley2003,

Even though you closed this question, I would like to add one point. When I recommended Real Basic, even though that version is different from MS Visual Basic, the language syntax is almost exactly the same(for programming issues, they refer people to the MSDN, that is how close it is to VB6). You wouldn't have to learn a new language, just learn the tiny little differences between Real Basic's IDE and Visual Basic's IDE. 99.9% of your existing code would not have to be changed at all. With Real Basic, the only differences code wise is with the MID keyword, but Real Basic provides a porting utility to handle things like that (porting utility is VB6 to Real B.).

Regardless of this questions status, I and Zamba would recommend you not use VB6. With Real Basic, you wouldn't have to re-write anything.

Good Luck anyhow.

Mugman
Thank you Mugman, I will look into that. I do believe I have used Real Basic before, and as you mentioned the syntax is close/exactly the same. Thanks for both of your posts.

Cheers,
Chuckie Ice

(aka Smiley2003)