Apply built-in style heading 1 to paragraphs where the word "Speaker"occurs

A

andreas

Dear Experts:

I would like to have a macro that performs the following task:

As soon as the macro hits the word "Speaker", built-in style heading 1
is to applied to the paragraph where the word "Speaker" occurs.

Help is much appreciated.

Thank you very much in advance.

Regards, Andreas
 
J

Jay Freedman

A macro isn't required for this. All you need is the Replace dialog.

In the Replace dialog, click the More button to expand the bottom half.

Click in the Find What box and enter the word Speaker. I assume you wouldn't
want to reformat a paragraph that contains that word in lower case, such as
"Tonight's speaker will be...", so be sure to capitalize it in the Find What
box, and check the box for Match Case.

Now click in the Replace With box. You can use the Special button and choose
the "Find What Text" entry, or just type the code ^& in the Replace With
box. Then click the Format button, choose Style, and select the Heading 1
style from the list.

Finally, click the Replace All button.

If you really want a macro for some reason, you can record one while doing
these steps.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 
A

andreas

A macro isn't required for this. All you need is the Replace dialog.

In the Replace dialog, click the More button to expand the bottom half.

Click in the Find What box and enter the word Speaker. I assume you wouldn't
want to reformat a paragraph that contains that word in lower case, such as
"Tonight's speaker will be...", so be sure to capitalize it in the Find What
box, and check the box for Match Case.

Now click in the Replace With box. You can use the Special button and choose
the "Find What Text" entry, or just type the code  ^&  in the ReplaceWith
box. Then click the Format button, choose Style, and select the Heading 1
style from the list.

Finally, click the Replace All button.

If you really want a macro for some reason, you can record one while doing
these steps.

--
Regards,
Jay Freedman
Microsoft Word MVP        FAQ:http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroupso
all may benefit.









- Zitierten Text anzeigen -

Hi Jay,

great. That's it. Thank you very much for your professinal help.

Regards, Andreas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top