Keyboard shortcuts in non-English version of Microsoft Office
I'm almost certain that there's not built-in way to change shortcuts in MS Office applications.
However, you can use AutoHotkey for this purpose.
The script
^a::
^f::
^s::
WinGet, Process, ProcessName, A
if(RegExMatch(Process, "^(WINWORD|EXCEL)\.EXE$"))
{
if(A_ThisHotKey = "^a")
SendPlay, ^e
if(A_ThisHotKey = "^f")
SendPlay, ^b
if(A_ThisHotKey = "^s")
SendPlay, ^g
}
else
SendPlay, %A_ThisHotKey%
return
How it works
^a::
, specifies one of the hotkeys that run the script before thereturn
statement, where^
indicates the Ctrl key.WinGet, Process, ProcessName, A
stores the active (A
) window's process name in the variableProcess
.-
if(RegExMatch(Process, "^(WINWORD|EXCEL)\.EXE$")) {...} else ...
checks ifProcess
matches the regular expression, i.e., if it matches one of the stringsWINWORD.EXE
orEXCEL.EXE
.-
If so, the first block gets executed.
-
if(A_ThisHotKey = "^a")
checks if the pressed hotkey is Ctrl + A.If it is, it simulates the key bombination Ctrl + E, which is the Portuguese hotkey to select all1.
-
-
Otherwise,
SendPlay, %A_ThisHotKey%
simulates the key combination that was initially pressed.This way, other applications still behave as they should.
-
How to use
Download and install the latest version of AutoHotkey.
Save the above script as
ms-office.ahk
, using your favorite text editor.Double-click the file to run the script.
If you wish, copy the script (or a link to it) in the
Startup
folder.-
To add further MS Office applications, just modify the regular expression.
To add PowerPoint, e.g., replace
(WINWORD|EXCEL)
by(WINWORD|EXCEL|POWERPNT)
. -
To add further hotkeys, you have to modify two parts of the script.
To add Ctrl + O (Open...), e.g., add the line
^o::
to the list at the very top add these lines inside theif
block:if(A_ThisHotKey = "^o") SendPlay, ^a
1 At least, I think it is. I took the hotkeys from my Spanish MS Office. Adjust if needed.
Based on the previous answer, a couple more shortcuts (could be added to the previous answer):
^a::
^f::
^s::
^w::
^n::
^u::
^d::
^r::
^b::
^i::
^k::
^g::
WinGet, Process, ProcessName, A
if(RegExMatch(Process, "^(EXCEL)\.EXE$"))
{
if(A_ThisHotKey = "^a") ;seleccionar rango
SendPlay, ^e
if(A_ThisHotKey = "^f") ;buscar
SendPlay, ^b
if(A_ThisHotKey = "^s") ;guardar
SendPlay, ^g
if(A_ThisHotKey = "^w") ;cerrar
SendPlay, ^r
if(A_ThisHotKey = "^n") ;nuevo libro
SendPlay, ^u
if(A_ThisHotKey = "^u") ;subrayar
SendPlay, ^s
if(A_ThisHotKey = "^b") ;negrita
SendPlay, ^n
if(A_ThisHotKey = "^i") ;cursiva
SendPlay, ^k
if(A_ThisHotKey = "^d") ;filldown
SendPlay, ^j
if(A_ThisHotKey = "^r") ;fill right
SendPlay, ^d
if(A_ThisHotKey = "^k") ;hyperlink
SendPlay, ^!k
if(A_ThisHotKey = "^g") ;goto
SendPlay, ^i
}
else
SendPlay, %A_ThisHotKey%
return