PRB: Developer Studio Hangs When Debug Breakpoint Is Set

Last reviewed: March 3, 1998
Article ID: Q177436
The information in this article applies to:

- Microsoft Visual C++, 32-bit Editions, version 5.0

SYMPTOMS

The Visual C++ debugger causes Microsoft Developer Studio to hang when a breakpoint is set in the code, or nothing happens when you try to start debugging with Debug Go (F5). It may also cause an application error in Msdev.exe. Also, The Visual C++ debugger might not run inside Microsoft Developer Studio, but it might run fine outside Microsoft Developer Studio.

CAUSE

If the software license checking program Express Meter is installed in the machine then it hooks a DLL named Em.dll in the process space of Msdev.exe. The Visual C++ debugger also uses a DLL by the same name. As a result, when the debugger is invoked in Microsoft Developer Studio it uses the wrong Em.dll found in its process space and the access violation occurs.

RESOLUTION

The Express Meter software is available in both 16-bit and 32-bit versions. When you are running this software, the 16-bit version appears in the Task Manager as EM (for Em.exe) and the 32-bit version appears as EM32 (for Em32.exe). Express Meter software installs the Em.dll in the Windows ..\System or ..\System32 directory. The Visual C++ debugger installs this DLL in the C:\Program files\DevStudio\SharedIDE\BIN\ directory if you installed Visual C++ in the C: drive.

To resolve this problem, check the following registry key:

   HKEY_CURRENT_USER\Software\Microsoft\DevStudio\5.0\Build System
     \Components\Platforms\Win32 (x86)\Execution Models

On the right panel you will see an entry "Current EM", and its value is set to "EM".

Change this value to the full path of the debugger's Em.dll for LoadLibrary to load the correct DLL.

The changed value will be similar to the following directory (depending on which drive Visual C++ is installed on):

   C:\Program files\DevStudio\SharedIDE\BIN\EM

To change the value, double-click "Current EM", and type in the full path that appears above.

If this does not resolve the issue, end the task (EM or EM32) from the Task Manager. Note that if the System Administrator is running this task in a secured mode, you need appropriate permissions to end this task.

STATUS

This behavior is by design.

Keywords          : VWBIss
Version           : WINDOWS:97
Platform          : WINDOWS
Issue type        : kbprb


================================================================================


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: March 3, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.