Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Spotlight doesn't work with MS Word files+!

1 view
Skip to first unread message

dfsdist...@yahoo.com

unread,
May 11, 2005, 12:06:46 PM5/11/05
to
Organizing my research files which were typed into multiple MSWord docs
over the years was THE ONLY REASON I wanted 10.4. Now I find that
"Spotlight" is choosey about which Word files it indexes--apparently. I
did all the required tests; I opened docs, found odd words or names,
and then Spotlighted them. At first it seemed promising. Many docs were
indexed until I noticed that many older ones still in earlier versions
of Word were not. I updated them to Word X and that seemed to work.
But, I found, it DID NOT work for all updated Word files. Now I am not
sure what IS and IS NOT indexed. Other docs including Pagemaker and
Freehand also have this problem--this is hardly what Mac advertised
Spotlight to be. I just bought an engine-less car!

Obfus Kataa

unread,
May 11, 2005, 3:21:34 PM5/11/05
to

Assuming you have the developer tools installed and that all your MS Word
files have the doc file type, in the terminal do

find ~/ -name "*.doc" -type f -exec /Developer/Tools/SetFile -t 'MSWD' {} \;
You may need to follow this with a
mdimport -r /Library/Spotlight/Microsoft\ Office.mdimporter

The file /Library/Spotlight/Microsoft\ Office.mdimporter/Contents/Info.plist
tells the file types currently understond by MS programs.

This may take a while. It worked for me when I created an mdimporter to
index elisp files.

--
oK+++

bauer777

unread,
May 23, 2005, 9:34:33 PM5/23/05
to
I am not sure how to do the terminal description you're saying. I'm
new to developer tools, is there anything I can learn to do it right?
Thank you.

Message has been deleted

Obfus Kataa

unread,
May 24, 2005, 9:45:13 AM5/24/05
to
Mon, 23 May 2005 (23:27 -0700 UTC) John Rethorst wrote:

> In article <Pine.OSX.4.62.05...@fjgied.kei>,


> Obfus Kataa <va...@finhut.fi.example.com> wrote:
>
>> Assuming you have the developer tools installed and that all your MS Word
>> files have the doc file type, in the terminal do
>>
>> find ~/ -name "*.doc" -type f -exec /Developer/Tools/SetFile -t 'MSWD' {} \;
>> You may need to follow this with a
>> mdimport -r /Library/Spotlight/Microsoft\ Office.mdimporter
>>
>> The file /Library/Spotlight/Microsoft\ Office.mdimporter/Contents/Info.plist
>> tells the file types currently understond by MS programs.
>>
>> This may take a while. It worked for me when I created an mdimporter to
>> index elisp files.
>

> This is the equivalent of creating a Spotlight plugin for that file type?

Sorry, the last two lines of my original are a non sequitur. Tiger appears
to include the plugin /Library/Spotlight/Microsoft\ Office.mdimporter
because it is on my system which already had Office installed. That plugin
has a Propoerty list which tells the plugin what OSTypes it indexes. Those
types cover all Office documents. I also knew (from years' past problems)
that Office's OSType designations had changed (perhaps for Office X v1).
So I knew that older Docs would not be considered indexable.

The last two lines of my reply refer to my own attempts to write a plugin,
which finally worked, and how I figured out how to make it work partly by
reading the Property list for Office.

By the way, there is a non-apple program available in a package named
OSXuitls, but it will not compile on 10.4 using gcc4. A version compiled
with gcc3.3 will run on 10.4. The program is setfctypes by Sveinbjorn
Thordarson.

In the instructions I wrote, the 'find ~/ ...' searchs the user's home
directory and all its subdirectories for files with names that have the
final file extension of 'doc' (but not 'DOC' -iname would include those
too). For each file it finds, it executes the SetFile command with the
settype parameter of 'MSWD'. The next command, 'mdimport -r ...' tells the
indexing server (mds) to reimport and search through files that the plugin
supports. I believe in this case that is necessary because the files have
already been catalogued in the initial search and not assigned to this
importer.

--
oK+++

0 new messages