
Signature
Russ
drsmN0SPAMikleAThotmailD0Tcom.INVALID
> Arthur,
> After running this macro, open the menu Edit/Replace...
> The dialog box should reflect the criteria that your macro setup for
> searching, since you are using a selection.find rather than a range.find.
Hello, Russ. Thanks for examining my problem.
I think that your advice has revealed an important clue. In the 'Find what'
field, after running the macro, I find the correct text. But underneath the
text I read (after 'Options: Search Down') 'Format: Left, Level 8, Border:
Top: (Single solid line, Auto, 0.75 pt Line width), B...'. Now, when I
recorded the macro (and when the operation I intend for the macro took place)
I specified nothing pertaining to border formatting.
> When everything looks good, then click on find next to test criteria again.
Once I specified all the paragraph formatting details, the line I quoted
above had changed to 'Format: Indent: Left: 1.5", Left Line spacing: single,
Space Before: 0 pt, After:...'. This information accurately describes the
formatting of the target paragraph. Nevertheless, when I searched, nothing
was found. (Note that when I originally recorded the macro, and when the
macro's purpose was achieved for the first and only time, the only formatting
I specified was that the outline level should be 8.)
> > I recorded a macro as I simultaneously (1) searched for all paragraphs of
> > outline level 8 and beginning with the text Œi.¹ followed by a tab character
[quoted text clipped - 51 lines]
> >
> > James Watson
Russ - 26 Nov 2007 18:42 GMT
A couple of more suggestions below:
>> Arthur,
>> After running this macro, open the menu Edit/Replace...
[quoted text clipped - 6 lines]
> field, after running the macro, I find the correct text. But underneath the
> text I read (after 'Options: Search Down')
If your cursor is already past any potential text that meets the criteria
and you set things up to Search Down, then you won't find any text from
where your cursor is to the end of the document. Usually you want to search
all the document or make sure the cursor is at the top of the document.
(Searching will only be in the main body of document and not in the headers
or footers, unless your cursor is already in a header or footer. You have to
resort to VBA code to iterate through and search all parts of document,
other than the main body text.)
>'Format: Left, Level 8, Border:
> Top: (Single solid line, Auto, 0.75 pt Line width), B...'. Now, when I
[quoted text clipped - 10 lines]
> macro's purpose was achieved for the first and only time, the only formatting
> I specified was that the outline level should be 8.)
Only specify the minimum criteria to find your text. Outline level 8 already
assumes certain formatting, you may be also specifying formatting that is
working at cross purposes from what Outline level 8 uses, and thus, the
combination of formatting to search for is impossible to find.
>>> I recorded a macro as I simultaneously (1) searched for all paragraphs of
>>> outline level 8 and beginning with the text Œi.¹ followed by a tab character
[quoted text clipped - 52 lines]
>>>
>>> James Watson

Signature
Russ
drsmN0SPAMikleAThotmailD0Tcom.INVALID
ArthurOfAlbion - 29 Nov 2007 16:47 GMT
> Only specify the minimum criteria to find your text. Outline level 8 already
> assumes certain formatting, you may be also specifying formatting that is
> working at cross purposes from what Outline level 8 uses, and thus, the
> combination of formatting to search for is impossible to find.
This is the heart of the matter. Once I began minimising my search
criteria, I discovered that even certain (perhaps all) left margin settings
are associated with other features (e.g., the presence of borders)! This
seems very much like bad design to me, but maybe there's a reason for it. I
ended up searching only for the characters corresponding to a given
paragraph's outline level (e.g., 'IV.^t').
Besides wondering why one cannot use a macro to search for individual
formatting criteria in isolation, I also wonder why the search I used for the
initial recording of the macro, which used the 'Outline level' formatting
criterion, actually did find the paragraphs with the correct outline level,
even though those paragraphs did not have the other characteristics
associated with that outline level.
Thank you again for solving my problem.
James Watson