EmEditor Macro Error - 'document' is undefined - emeditor

I used EmEditor for years now. Now I want to create and use a simple macro.
But every time a run a macro I get the error message:
'document' is undefined
I can fix the problem by deinstallation and a new installation of Emeditor.
But after a reboot, the same error will be show again.
I use EmEditor Professional 64-bit Version 22.2.0 on a Windows 10 22H2.
I had this issue also in the past, on a different notebook.
So this issue seems to be independend of my windows installion.
There is no third parts virus scanner installed, only windows defender.
EmEditor is installed in the standard path.
This error happens with the default marcos like ValidateXml.jsee or also with self recored and save macros.

If you run EmEditor as Administrator, please run EmEditor as non-Admininistrator. Please run emeditor.exe without a shortcut to see if macros run correctly.

Do you can run macro's from clipboard?
Please try it for example with "alert(document.name)".
Put this between "" to clipboard and select in menu macros - run clipboard.
In normal case you get an popup with the actual document name.

Related

Command Prompt Changing Colors after Compile

Whenever I run a compiler on a bash cmd and I get an error, the command prompt changes back to 'default' like colors. It stays like this till I change it manually again.
I have tried changing "right click->properties->color" and "right click->defaults->color" and I have went where the cmd is in the file system and change the color through properties. Same problem occurs.
I am very unsure where else I could change the color to fix this problem.
System = Razerblade Steath 2017
OS = Updated Windows 10
Compilers Using = g++ and gcc (same problem on both)
Picture of how and when it occurs. The code I am running is just one line in the main function purposely giving an error.
You can use -fno-diagnostics-color on your command line to disable this. gcc tries to determine if your window supports color and it will use it to try to make the error messages easier to read. Apparently, it's not restoring the original colors correctly.
Windows command prompts stopped supporting color long ago, but that feature has recently be re-enabled in one of the Windows 10 releases.

visual studio code "launch json" on run, how to set debug console as default

I went to user settings to set the debug console to default (when I try to debug now the default console is terminal. I lose the small debug icons to skip, stop etc even when I manually select debug console). I am watching Python tutorials using Vs Code and his default is debug. How can I do this?
Secondly, when I try to run or debug, I am prompted to open LaunchJS, even if it is already open. I attempted to run it using the debug selection "current file, integrated terminal" and also "Python: Attach". Neither will work although the JSON file has these options. I looked at some MS videos but I am not understanding the problem.
Any help is appreciated. Thanks.
I found the answer at this link: https://code.visualstudio.com/docs/python/python-tutorial
I had not selectd a Python interpreter which establishes a python workspace. Was just trying to run with debugger. A simple program now runs. My guess is that the Python tutorial I selected is too old to follow with this version of VS Code, since I am unfamiliar with any version of VS Code.
Thanks.

Keyboard shortcut to quit kernel in Mathematica 5 and 7?

Here is an explanation how to define a custom keyboard shortcut for quitting the kernel of the selected notebook by modifying the file KeyEventTranslations.tr. This file is located by default (under Windows) for Mathematica 5.2 in the folder
C:\Program Files\Wolfram Research\Mathematica\5.2\SystemFiles\FrontEnd\TextResources\Windows
and for Mathematica 7.0.1 in the folder
C:\Program Files\Wolfram Research\Mathematica\7.0\SystemFiles\FrontEnd\TextResources\Windows
In this file after EventTranslations[{ I have added a line:
Item[KeyEvent["q", Modifiers -> {Control}],FrontEndExecute[FrontEndToken[SelectedNotebook[],"EvaluatorQuit",Automatic]]]
But unfortunately after restarting Mathematica the shortcut Control+q does not work on both versions.
Moreover, in Mathematica 7.0.1 executing the command
FrontEndExecute[FrontEndToken[SelectedNotebook[], "EvaluatorQuit", Automatic]]
and pressing "Quit" leads to an application error and closing FrontEnd with loosing all unsaved changes (I am using Windows 2000).
What am I doing wrong?
EDIT: The problem was in missing comma after added Item[...] (thanks to belisarius). Here is the right line to add to KeyEventTranslations.tr:
Item[KeyEvent["q", Modifiers -> {Control}],FrontEndExecute[FrontEndToken[SelectedNotebook[],"EvaluatorQuit",Automatic]]],
Now shortcut Control+q works nice both in Mathematica 5.2 and 7.0.1.
But the above bug with "application error" still appears (not when using the shortcut but only when evaluating FrontEndExecute[FrontEndToken[SelectedNotebook[], "EvaluatorQuit", Automatic]] in notebook).
This answer and the associated comments may help you.
HTH!
BTW ... I did the same in v7 and it worked. On what version are you having trouble?
Just a note: Be very careful with the syntax Verify that every Item[Keyevent ends with a comma, except the last one.

Using GlobalFlags to call vsjitdebugger with VS2010

I've upgraded to Win7 and VS2010. Previously on Win2K and VS2008, I used GlobalFlags to debug an application on startup, simply by setting it's debugger to vsjitdebugger - see the screenshot below. Unfortunately, this doesn't work on my current setup - a google and search of SO haven't turned up any answers.
Thanks in advance.
UPDATE: Forgot to mention that my global flags settings do seem to have some effect - running my command on the command line causes Windows to say the program has crashed - it works just fine without the global flags. This is leading me to think my command line for the debugger is incorrect - but that's just a guess. I'd be interested in hearing from anyone who's got this to work.
alt text http://img825.imageshack.us/img825/3538/55489547.png
Running the 64-bit version of Windows 7? Using the 32-bit version of gflags.exe?
You can also edit the registry directly. An example .reg file for notepad.exe:
REGEDIT4
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe]
"Debugger"="vsjitdebugger.exe"
Run the VS2010 on Win7 with administrator privilege, "vsjitdebugger.exe" works fine.
It looks like there's an extra step in Win7 which I wasn't expecting - it throws up a "MyProgram has stopped working" screen first. If you look at the details, it says it's an application crash.
You get the options:
"Check online for a solution and close the program"
"Close the program"
"Debug the program"
Clicking debug then pops up the vsjitdebugger dialog and all is well.

VB6 lost F1 help function after Install of VS2005, re-install of MSDN2001 did not work

After installing VS2005 VB6 lost F1 function to MSDN Oct/2001 lib.
Suggestions to re-install MSDN did not work.
The only thing F1 works on now are ADO statements in VB6. Example ado1.recordset.recordcount If I highlight recordcount and press F1 I do get the ADO help information. If I highlight "recordset", I get "Help not found" dialog.
Same with say any regular VB tools property. lblEvent.Caption Get error trying to find help on say caption. If I highlight say Next in a for next loop I get a dialog that wants to know ... Multiple instances of the selected word have been found. Please select a topic and press Help. In this case VBA is one, Excel is one MSComctlLib is one. If I highlight FOR in a statement I get the "Help Not Found" error again.
This happened to me once. The only thing I could do to fix it was a complete re-install of VB6 (wasn't caused by installing VS2005, but installing a component that added its own doc to Help). Probably not what you want to hear.
This happened to me after a Windows Update, or maybe it was one of the XP service packs. Un-installing hotfix 896358 solved my problem.
Something similar happened to me, trying to compile a vb6 dll wasn't working.
Turns out that an update had been installed in the background and i needed to reboot before it would allow me to compile it again.

Resources