This bug is revealed in the following case:
1. Run AkelPad and open any file.
2. Run FindReplaceEx.js.
3. Switch to another task (eg. Firefox).
4. Switch to AkelPad.
5. Open RegExp help (F1 key or click link "?").
6. Wait a few seconds.
7. AkelPad is frozen.

Instructor
It does not solve the problem.
This piece of code is executed only when is opened the window "FindReplace templates" (bFRT==1). In this case, the script is working properly.
The error occurs when the window "FindReplace templates" is closed (bFRT==0).