Anil D

Hello All,

Can you please confirm, if there is any Manager interface available for adding Folders to Windows Search

Also if we can do such configurations, is it possible to configure indexing time (What are the limits for the same)

Please confirm if there are any Code sinpeets somewhere

Thanks in advance,

Anil



Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Jeff Zhang (MSFT)

You could use Windows Search API to add "search root" and "scope rule" to the indexer, it is the same as you add a new folder to index in Search-Option control panel applet. Please check the dev reference in http://msdn2.microsoft.com/en-us/library/bb266541.aspx
Thanks.




Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Anil D

Hi,

Thanks for your inputs.

The Apis AddScopeRule APIs are working fine in XP

But they are not working in the Vista.

I get exception - as AccessDenied.

I think there is a security issue with File System and using APIs I am not able to add it.

Thanks And Regards,

Anil





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Ari Polsky - MSFT

Did you try running your app as adminstrator





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Anil D

Yes,

It works fine when I run it as Administrator.

But since I am the Administrator - of my desktop, it should work fine.

Please let me know - if I need to do anything special for the Vista applications to make sure that they work in any mode.

Regards,

Anil





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Ari Polsky - MSFT

Even when you are logged in as a member of the Administrator's group, not everything you run automatically runs with admin privileges. This is because of Vista's new security feature, UAC. See this article for details:

http://technet2.microsoft.com/WindowsVista/en/library/0d75f774-8514-4c9e-ac08-4c21f5c6c2d91033.mspx mfr=true





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Anil D

Hi,

I have tried many things till now.

The only solution I see - is having COM wrapper which itself can be elevated. When called from cleint - this elevated COM wrapper would in turn call all WDS APIs.

IF anyone of us have written something like this, please let us know.

Thanks And Regards,

Anil





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

David Washington [MSFT]

Did you try running your tool as administrator

Right-click > Run as Administrator.





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Anil D

Run As Administrator works.

But I dont want that since for standard user - addition and deletion of scope rule does not require any special priviliges when using control panel.

I am still investigating any options where I can perform it in the background (code) without admin elevation.

Regards,

Anil





Re: Windows Desktop Search Development Windows Search - How to Add folders for indexing - automatically

Ari Polsky - MSFT

In fact the Indexing Options control panel does require elevation to change per-machine scope rules such as local drive indexing. When you click the modify button in Indexing Options you will at first only see per-user indexed locations (e.g. email) unless you click the show all locations button, which does indeed require elevation.