Tuesday, July 27, 2021

An AutoHotkey solution to a memoQ problem

The memoQ problem…

Some installations of memoQ suffer an annoying problem: cut and paste doesn’t work. The rest of the program works, as does copy and paste, but not the "paste" part of cut and paste: memoQ deletes your text at Ctrl+X all right, but it does not save it to the clipboard, so you have nothing to paste when you hit Ctrl+V.

If you try to perform the operation via the context menu, no luck, either: after Ctrl+X, paste (Ctrl+V) is greyed out.

Cut and Paste not working in memoQ

The problem appears unpredictably: you could have (as I do) two similar computers, with a similar panoply of software installed. On one cut and paste works as expected in memoQ, while in the other it doesn't.

memoQ’s support staff are aware of this problem, but (since they have never been able to reproduce it) their developers are unable to fix it. memoQ's support offer several suggestions that sometime work, from disabling other programs that might interfere with the clipboard, to deleting certain temporary files, and finally to that old favorite of all support organizations: reinstalling the program… but even reinstallation, for certain users, fails to correct the problem.

Fortunately, there is a simple workaround: instead of hitting Ctrl+X to cut and Ctrl+V to paste, you can add a step—copy (Ctrl+C), delete (Del), and finally paste (Ctrl+V)—but if you are accustomed to just using Ctrl+X/Ctrl+V in all other programs, you are likely to forget that you have to use different steps in memoQ.

...and the AutoHotkey solution

So we need a more permanent solution, and one is at hand (this also is thanks to a suggestion from memoQ support): using an AutoHotkey1 script to replace the “cut” part of cut and paste.

Here is the script (complete with comments to explain what each step does):

#NoEnv  		; Recommended for performance and compatibility with future 
                        ; AutoHotkey releases.
SendMode Input  	; Recommended for new scripts due to its superior speed 
                        ; and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
^x:: 			; Assigns to the Ctrl+X shortcut the following actions:
#IfWinActive memoQ 	; ensures script works with memoQ only, not with other programs
Send ^c 		; Copy (as if "Ctrl+C" had been pressed)
Send {del} 		; Delete (as if the "Delete" key had been pressed)
#IfWinActive 		; end of the "works in memoQ only" part of the script
Return 			; end of the script

You can use this script "as is" if you already have AutoHotkey installed: just copy the above code to an empty text file and save it with an .ahk extension; then, whenever you need to work in memoQ, double click on the script file to launch it.

If you use other AutoHotkey scripts, you also can add the above code snippet to one of your other scripts (so long as none of them tries uses Ctrl+X as a hotkey). And you can even compile the script to an independent .exe file, to use on computers where AutoHotkey is not installed.


1 AutoHotkey is a free, open-source scripting language for Windows that allows users to easily create small to complex scripts.


  1. I saw your presentation on Innovation in Translation and I really appreciate your solution to the memoQ bug. Since the bug is intermittent, I just thought there was some problem with my computer, or with my cut-paste technique; I never thought it was a memoQ problem. Now I know I'm not the only one to be frustrated using memoQ... and now I have a solution. Thank you.

  2. Your blog is very good. because I am a student, this semester who is studying translation. I wanted to ask this, I hope you answer my question. the question is do you know the difference between scientific translation and literary translation?
    thank you hope you help me by answering this question

    1. Hello Humairah,
      To answer very briefly to your question:
      For scientific (or technical) translation, knowledge of the subject matter (i.e., what the text is about) is of paramount importance. For literary translation what is most important is the quality of the translator's writing, and how best she can convey in her writing the qualities of the original text.
      But in scientific translation also the quality of writing is important, and in literary translation understanding all the nuances of the source text is equally important.

  3. I had a similar problem that I reported to MemoQ, although it only affected the copy buffer if I copied something, inserted something from the TM/term match window using CTRL-[number], and then tried to paste in whatever I had copied previously (it would paste in "number" instead). The tech support person said that this was just part of how Windows' copy/paste buffer worked (despite the fact that it hadn't been an issue before, and after a period of time and possibly an update it went back to working correctly).

  4. And here it is again without the extra stuff I had to delete, but still grateful!

    SendMode Input
    SetWorkingDir %A_ScriptDir%
    #IfWinActive memoQ
    Send ^c
    Send {del}


Thank you for your comment!

Unfortunately, comment spam has grown to the point that all comments need to be moderated. All legitimate comments will be published as soon as possible.