Can this be done? I think the standard AutoCorrect only works on whole words...
One solution: Bind
wdKeyE to the following macro
Sub my_e() Select Case (Selection.Previous(wdCharacter, 1)) Case "a" Selection.TypeBackspace Selection.TypeText ChrW(228) 'other cases, as desired Case Else Selection.TypeText "e" End Select End Sub
The key binding can be done with:
KeyBindings.Add KeyCategory:=wdKeyCategoryMacro, Command:="my_e", KeyCode:=wdKeyE
Sub e_unbind() Dim cmds As Variant Dim bind As KeyBinding For Each bind In Application.KeyBindings If bind.KeyCategory = wdKeyCategoryMacro Then cmds = Split(bind.Command, ".") If cmds(UBound(cmds)) = "my_e" Then bind.Clear End If Next End Sub
...Works well so far
As this has been migrated to SuperUser, it seems reasonable to include some of the comments as an answer.
@Otaku noted that a combination of keys would produce the required accent, based on this comment I found a list that details the accents that can be added with key combinations and an English or US keyboard layout. This is apart from the accents that can be got by using Alt Gr.