How to change the description of an service shown in SCM
C / C++ / MFC
2
Posts
2
Posters
0
Views
1
Watching
-
How to change the description of an service shown in SCM
-
How to change the description of an service shown in SCM
SC_HANDLE hSCM; hSCM = OpenSCManager( NULL, NULL, SC_MANAGER_ALL_ACCESS ); if(hSCM==NULL) { LOGERROR("ERROR opening SC manager"); } SERVICE_DESCRIPTION sd; sd.lpDescription=sDescription; SC_HANDLE hService=OpenService(hSCM, "My Service", SERVICE_ALL_ACCESS); ChangeServiceConfig2(hService, SERVICE_CONFIG_DESCRIPTION,&sd); CloseServiceHandle(hService); CloseServiceHandle(hSCM);
It's not a bug, it's an undocumented feature.
suhredayan@omniquad.commessenger :suhredayan@hotmail.com