Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
I often record a macro to repeat often-used keystrokes, but today I found a
keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Some things you cannot do with the macro recorder and you have to code by
hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Some things you cannot do with the macro recorder and you have to code by hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com |
#4
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Thanks Graham. That's great.
-- Richard Using Office 2003 & Win2kpro Search the web and raise money for charity at www.everyclick.com "Graham Mayor" wrote: Some things you cannot do with the macro recorder and you have to code by hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com . |
#5
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Thanks Graham. That's great.
-- Richard Using Office 2003 & Win2kpro Search the web and raise money for charity at www.everyclick.com "Graham Mayor" wrote: Some things you cannot do with the macro recorder and you have to code by hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com . |
#6
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Thanks Graham, that's great.
-- Richard Using Office 2003 & Win2kpro Search the web and raise money for charity at www.everyclick.com "Graham Mayor" wrote: Some things you cannot do with the macro recorder and you have to code by hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com . |
#7
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Edit Field - Format settings
Thanks Graham, that's great.
-- Richard Using Office 2003 & Win2kpro Search the web and raise money for charity at www.everyclick.com "Graham Mayor" wrote: Some things you cannot do with the macro recorder and you have to code by hand. In this case you want to add a Firstcap switch to a selected field. The following is one way to do that Sub AddFirstCap() Dim oField As Field Set oField = Selection.Sentences(1).Fields(1) If InStr(1, oField.Code.Text, "\*Firstcap") = False Then oField.Code.Text = oField.Code.Text & " \*Firstcap" End If oField.Update End Sub http://www.gmayor.com/installing_macro.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org "RichUE" wrote in message ... I often record a macro to repeat often-used keystrokes, but today I found a keystroke that couldn't be recorded. I use Tools, Macros, Record a new Macro and assign it to a toolbar. In my document, I have some cross-references to bookmarks. Some bookmarks begin with a lower-case letter (due to the context in which they are used), but this may be changed in the cross-reference by right-clicking on the field, Edit field, Format - First capital. However, when trying to capture this sequence in a macro recording, the right-click function is not available. Is there an alternative keystroke I can use? I couldn't find a relevant menu option. -- Richard Using Office 2003 & Win2kpro (soon to be Office 2007 & W7) Search the web and raise money for charity at www.everyclick.com . |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Locked table settings not saved and edit mode switched on | Tables | |||
can I change time field settings to 24hr clock format in mail merg | Mailmerge | |||
How to edit if-then word field? Not same as merge field! | Microsoft Word Help | |||
Can't find explanation of Word Options, Edit, Cut&Paste, Settings | Microsoft Word Help | |||
How can I edit the format of a mail merge field after it has been. | Mailmerge |