Reply
 
Thread Tools Display Modes
  #1   Report Post  
George M. Lutz
 
Posts: n/a
Default Search up (or down) ONLY

Can I write a macro that searches a document from the insertion point up, only?

Your help is greatly appreciated.

George Lutz
  #2   Report Post  
Jay Freedman
 
Posts: n/a
Default

George M. Lutz wrote:
Can I write a macro that searches a document from the insertion point
up, only?

Your help is greatly appreciated.

George Lutz


Hi George,

In the Selection.Find object in your macro, set .Forward = False and .Wrap =
wdFindStop. To search down instead, use .Forward = True.

If the selection might be extended (more than one character) when the macro
starts, you might want to insert the statement
Selection.Collapse wdCollapseEnd
before starting the search.

--
Regards,
Jay Freedman
Microsoft Word MVP FAQ: http://word.mvps.org


Reply
Thread Tools
Display Modes

Posting Rules

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Keyboard shortcut to repeat a search Bob Day Page Layout 1 January 12th 05 03:05 AM
For inserting symbols in Office there should be a search function reemal Microsoft Word Help 1 January 8th 05 07:49 PM
For inserting symbols in Office there should be a search function reemalm Microsoft Word Help 1 January 8th 05 03:54 PM
search and replace symbol characters Patricia G. Kurz Microsoft Word Help 1 December 29th 04 03:11 AM
Search facility Michael Quin-Conroy Microsoft Word Help 1 December 14th 04 10:23 AM


All times are GMT +1. The time now is 05:48 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"