Old 23rd November 2009, 14:46   #1
kuroSAVVAS
Junior Member
 
Join Date: Jan 2009
Posts: 6
Question Turning Windows 7 features on and off

I have a project that uses the windows indexing service through Microsoft sql 2008 server. Now Microsoft decided to get rid of this service starting from vista and replaced it with windows search. The thing is that i still need the indexing service for 2 reasons. One is existing code and second is that Microsoft's driver for windows search from sql server does not work!

I found online that you can enable the indexing service again by going to
Start > Control Panel > Programs > Programs and Features > Turn Windows Features on or off > Indexing Service

and it works just fine. The problem is that i would like my installer to automatically enable this service. Note that this is not a matter of simply enabling a service (i know how to do that). This is a feature of windows not enabled by default and i need a way to do it automatically.

Any thoughts?
kuroSAVVAS is offline   Reply With Quote
Old 24th November 2009, 09:31   #2
CancerFace
Senior Member
 
Join Date: Apr 2006
Posts: 289
Send a message via ICQ to CancerFace
The Indexing service is called CISVC and can be found in
code:
[HKLM]\SYSTEM\CurrentControlSet\services\CISVC

You can check if the key exists or use the service plugin to check if the service is installed and if not create it.
Alternatively you can use the sc.exe command invoked from nsExec to create the service:
code:
nsExec::ExecToLog '"$SYSDIR\sc.exe" create CISVC binpath= "$SYSDIR\cisvc.exe" type= share DisplayName= "@$SISDIR\CISVC.EXE,-1" start= auto depend= RPCSS'


You may want to manually modify some registry entries after that (adding a description etc). Have a look at the bottom of this page to get an idea.
Note that you need elevated privileges to do all the above.
Hope this helps,
CF
CancerFace is offline   Reply With Quote
Old 24th November 2009, 14:29   #3
kuroSAVVAS
Junior Member
 
Join Date: Jan 2009
Posts: 6
As it turns out i found a way to enable windows features through the command line. For the indexing service i use this:

ExecWait 'ocsetup.exe Indexing-Service-Package /passive /quiet'
kuroSAVVAS is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump