Re: Get ViEmu working under experimental hive

I am developing an IronPython project. This requires me to launch Visual Studio's experimental hive mode that comes with the Visual Studio SDK. Does anyone know how to enable ViEmu under these conditions?



Re: Get ViEmu working under experimental hive

Hello Tomlu,

At least one other customer has been able to set up ViEmu with the experimental hive and with IronPython Studio (I understand they're not related?). I use ViEmu in the experimental hives of all VS versions with no problems, for debugging myself. There shouldn't be a problem in setting it up once you know how to do it.

What version of Visual Studio are you using? The "Experimental Hive" has changed places in VS 2008 (from an HKLM location to an HKCU location, in order to work with non-administrator accounts), and the instructions are different.

Here's what actually needs to be done: you need to add the registry entries that hook ViEmu into the Visual Studio registry hive used by the installation you are using. I'm going to post these entries here in text form, as they look like for integration in Visual Studio 2005. For other installs, it's enough to substitute the following location:


By whatever is needed, in all places where it appears. In a test install I did of IronPython Studio, the relevant key was:


You only need to copy the contents below, save it in a text file with a ".REG" extension, do the adequate substitution and double click the .REG file.


  -- Jon

Windows Registry Editor Version 5.00








"InProcServer32"="C:\\Program Files\\ViEmu\\ViEmu.dll"
"CompanyName"="NGEDIT Software"

"Path"="C:\\Program Files\\ViEmu\\"


"Name"="ViEmu Marker Service"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Text Editor]

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Text Editor\External Markers]

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Text Editor\External Markers\{0B461F6D-8F34-494A-A07A-2EC3D6118833}]
@="ViEmu hlsearch Marker"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Text Editor\External Markers\{759C9305-6031-46EF-B32D-BDCFAE8BF8B2}]
@="ViEmu Incremental Search Marker"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Text Editor\External Markers\{E3A0CE66-9EA5-43B5-B5A3-EC36F5A61255}]
@="ViEmu Selection Marker"





Re: Get ViEmu working under experimental hive

Thanks for the swift response.

By replacing the path with 8.0Exp instead of 8.0, I was able to get ViEmu to load. However, while the fat cursor indicates that ViEmu is up and running, all keypresses have their normal, non-ViEmu effect. I added the same registry information to the 8.0 (normal) hive, and it keeps on working as expected. Any more clues?


Re: Get ViEmu working under experimental hive

After looking into it some more, I have additional information.

It appears that I need to open a .cpp or .cs (and probably others) before ViEmu starts working. After I have opened one once, ViEmu kicks in on all .py files as well. Opening several .py files does not work unless I open a non-.py file as described above.

It is most peculiar. I can of course live with this even if it is a bit inconvenient to have to open a cpp file once per startup.


Re: Get ViEmu working under experimental hive


Do you have Visual Assist installed but non-functional for some reason? That would be the most likely cause.

ViEmu has to wait until VAX subclasses the editor window, before subclassing it itself. This is so that it will see keypresses before VAX and everything will work correctly (normal mode keystrokes shouldn't get to VAX, else it will start popping up nonsensical autocompletion drop downs). Also, there is no good way to detect whether VAX will or will not subclass a certain editor window after some time (it takes it time before subclassing, don't ask me why), so I resort to looking at the add-in list. If VAX is present in the list, but inactive (for example: an expired trial), then ViEmu will wait for ever, and you'll get the behavior you describe.

The "block cursor" in this mode is intentional, I do a double subclass ("the pinch"), to be able to operate before VAX does its thing, and I force the block cursor even before the real subclass for aesthetic purposes.


  -- Jon


Re: Get ViEmu working under experimental hive

That is precisely the correct analysis. VAX is installed but was not loading correctly in the experimental hive. Disabling add-ons fixes my problem; next, I guess I'll try to get VAX to run as well even though it won't be useful for my Python project.

Thanks Jon!


Re: Get ViEmu working under experimental hive

You're welcome, I end up having too much familiarity with common 3rd-party-add-in-induced errors...


  -- Jon


Re: Get ViEmu working under experimental hive

FIY, I was able to get it working using both VS2005 and IronPython Studio using the above method.


Re: Get ViEmu working under experimental hive

Great, glad to hear that! Thanks for posting your experience.


  -- Jon