Afternoon,
I found this code to change all the cross references to lower case, e.g. "Figure 3 shows ....." becomes "figure 3 shows .....", all cross references change to lower case. I want to add a condition that when the cross reference is in the beginning of a sentence, the case must remain upper case, e.g. ".... after ten years. Figure 3 shows ....." and not ".... after ten years. figure 3 shows ....." but in the middle of a sentence it should be ".... as seen in figure 3..." and not "...as seen in Figure 3..."
This is the code:
```
Sub FieldRefChanges1()
On Error Resume Next
Dim oStoryRng As Range
Dim oFld As Field
For Each oStoryRng In ActiveDocument.StoryRanges
For Each oFld In oStoryRng.Fields
If oFld.Type = wdFieldRef And oFld.Result.Words.Count <= 2 Then
'add format switch with lowercase option to field codes
oFld.Code.Text = oFld.Code.Text & "\* lower "
'updates the field results to display the new format
oFld.Update
End If
Next oFld
Next oStoryRng
End Sub
```
Please assist.
Regards
Caswell1000
Bookmarks