Solved

NT service - description field?

Posted on 2000-03-08
6
342 Views
Last Modified: 2013-12-03
I have an application which is an NT service.  Everything seems to be working okay, except that in the Service Properies in NT my description field is blank.  Where can I populate this from my program when it installs itself as a service?

Thanks,

Don
0
Comment
Question by:dmetzler
6 Comments
 
LVL 86

Expert Comment

by:jkr
ID: 2598297
Sorry, but what do you mean with 'Service Properties'?
0
 

Author Comment

by:dmetzler
ID: 2598546
When I go into the Component Services (Win2000 Pro) and bring up the properties for my service, the description field in blank.  Most of the other services have this field filled in.
0
 
LVL 2

Expert Comment

by:bbousquet
ID: 2598623
If I properly recall from what we're doing with our device driver, this is stored in one of the registry keys (I might be mistaken though - it's been awhile...).
0
SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

 

Author Comment

by:dmetzler
ID: 2598916

>>
If I properly recall from what we're doing with our device driver, this is stored in one of the registry keys (I might be mistaken though - it's been awhile...).
>>

So it's not a parameter on CreateService() or something?  Sounds like I have to create the service and then edit the registry key?

Don
0
 
LVL 2

Expert Comment

by:bbousquet
ID: 2599036
It might be. I was just guessing here.

But you're right, it is a parameter on the CreateService API function.
0
 
LVL 32

Accepted Solution

by:
jhance earned 100 total points
ID: 2599907
You must add this information manually to the registry using RegSetValueEx() as CreateService doesn't provide a way to add this to the service database using the SCM API.

To quote the SDK CreateService:

Remarks
The CreateService function creates a service object and installs it in the service control manager database by creating a key with the same name as the service under the following registry key:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services

Information specified for this function is saved as values under this key. Setup programs and the service itself can create subkeys under this key for any service specific information.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Windows Process running 3 61
Convert GUI app into console app for Win32 Env 5 125
SSRS troubles 4 82
Trouble installing msi file with msiexe.exe 2 16
This article shows how to make a Windows 7 gadget that extends its U/I with a flyout panel -- a window that pops out next to the gadget.  The example gadget shows several additional techniques:  How to automatically resize a gadget or flyout panel t…
This article describes how to programmatically preset the "Pages per Sheet" option that's available with most printer drivers.   This setting lets you do "n-Up" printing, where two, four, or more pages are printed on each sheet of paper. If your …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question