r591
05-06-2010, 01:06 AM
Hi, all!
It is enjoyble to learn WORD macros and seek help here.
I have a question as follows.
The title of an article is like this:
study on management mechanism in construction of energy saving monitor systems
By using:
Selection.Range.Case = wdTitleWord
I can get:
Study On Management Mechanism In Construction Of Energy Saving Monitor Systems
But, I don't want "on", "in" or "of" be capitalized.
That is, I'd like to have a macro to capitalize the first letter of each word in a selection, but leave the specified words in lowercase.
If I remember it correctly, "IF THEN" in APPLE BASIC can work with something like "DATA: "in", "on", "of"......" to specify such words to be in lowercase. It is quite convenient. Is there any similar way in VBA? If not, what is the easiest?
A complete macro is highly appreciated!
It is enjoyble to learn WORD macros and seek help here.
I have a question as follows.
The title of an article is like this:
study on management mechanism in construction of energy saving monitor systems
By using:
Selection.Range.Case = wdTitleWord
I can get:
Study On Management Mechanism In Construction Of Energy Saving Monitor Systems
But, I don't want "on", "in" or "of" be capitalized.
That is, I'd like to have a macro to capitalize the first letter of each word in a selection, but leave the specified words in lowercase.
If I remember it correctly, "IF THEN" in APPLE BASIC can work with something like "DATA: "in", "on", "of"......" to specify such words to be in lowercase. It is quite convenient. Is there any similar way in VBA? If not, what is the easiest?
A complete macro is highly appreciated!