If you are like me from Germany, but used to writing on a EN-US or EN-GB keyboard layout, you probably ran into the problem of writing special characters like “ä”, “ü” or “ß”.
This is why I searched for a more simple solution then changing the layout with WIN+SPACE frequently.

For me the best solution was an AutoHotkey script. AutoHotkey is great for several reasons:

  • It can be interpreted or compiled and used as an executable (ok, this has also security implications, but let’s ignore them for this post)
  • It is extremely easy to learn and to write but also has the tools for complex scenarios
  • It has a great community to help out

You can find the download and more information on their official site: AutoHotkey Website

So first I wrote down the characters I frequently use:

  • ä/Ä
  • ü/Ü
  • ö/Ö
  • ß

Then I searched for a shortcut that has the least possible overlap with the programs I use daily like VSCode and the Office suite.
For me this combination was Ctrl + Alt + {letter}. Where the letter is u for ü, o for ö, etc..
It was only intuitive to choose the same combination just with the addition of Shift for uppercase.

This is what the basic AHK script looked like:

umlauts.ahklink
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
SetTimer,UPDATEDSCRIPT,1000
UPDATEDSCRIPT:
FileGetAttrib,attribs,%A_ScriptFullPath%
IfInString,attribs,A
{
FileSetAttrib,-A,%A_ScriptFullPath%
SplashTextOn,,,Script was updated,
Sleep,500
Reload
}
Return
#SingleInstance, Force

OSD(text)
{
#Persistent
Progress, hide x1050 Y900 b1 w150 h27 zh0 FM10 cwEEEEEE ct111111,, %text%, AutoHotKeyProgressBar, Verdana BRK
WinSet, TransColor, 000000 120, AutoHotKeyProgressBar
Progress, show
SetTimer, RemoveToolTip, 1000
Return
RemoveToolTip:
SetTimer, RemoveToolTip, Off
Progress, Off
return
}

RAlt & a::
{
If GetKeyState("Ctrl","P")
If GetKeyState("Shift","P")
Send Ä
else
Send ä
return
}

RAlt & u::
{
If GetKeyState("Ctrl","P")
If GetKeyState("Shift","P")
Send Ü
else
Send ü
return
}

RAlt & o::
{
If GetKeyState("Ctrl","P")
if GetKeyState("Shift","P")
Send Ö
else
Send ö
return
}

RAlt & s::
{
If GetKeyState("Ctrl","P")
Send ß
return
}

RAlt & e::
{
If GetKeyState("Ctrl","E")
Send €
return
}

RAlt & F7::
Send {Media_Prev}
return

RAlt & F8::
Send {Media_Next}
return

The first part of the script is mainly for testing and developing of the AHK script. You probably don’t need it, once you are finished.
The OSD(text) part from line 14 onwards is mainly for testing and using media buttons and emulating OSD’s. Just drop it, if you don’t need media interaction.
I also added some AutoHotkey shortcuts for media buttons starting at line 72 (next/previous track).

If you need additional special characters, just use the existing ones as template, save the script and be more productive!

If you need the script at startup, just take the compiled exe and throw it in you “Startup” folder at shell:startup.