How to debug a managed BHO from Visual Studio 2010
Asked Answered
D

1

6

I've a managed Explorer Bar (working in Internet Explorer) that is working reasonably well. Currently, the only way to debug it:

  1. Start IE outside VS
  2. From VS (Debug => Attach) Attach to the process "iexplore.exe"

Trying to do the following:

  1. Go to Project Properties => Debug tab
  2. Start External Program: c:\program files (x86)\internet explorer\iexplore.exe
  3. Command line argument: about:blank
  4. Hit F5

The first method is very cumbersome. With the second method, iexplore starts, but the debugger doesn't recognize the breakpoints, don't know why.

Any tip?

Demers answered 25/12, 2011 at 14:15 Comment(4)
What happens in the second method?Folacin
@gideon, with the second method, iexplore starts, but debugger doesn't recognize the breakpoints.Demers
edited/updated your question, you don't need html for format lists.Folacin
possible duplicate of Why can't I debug from Visual Studio 2005 after installing IE8?Borodino
D
5

So ... 3 months after I opened this question, here is the answer. In Visual Studio, open an EXE as a new project:

  1. File -> Open -> Project/Solution
  2. Change type to exe file
  3. Open c:\program files\internet explorer\iexplore.exe

then, open project property:

  1. There is only one 'General' tab
  2. Change Debugger Type to 'Managed v4.0'

That's it. F5 will now work. You can add this EXE project to the solution that contains your managed bho, and set the EXE project to be the Startup project.

Demers answered 12/3, 2012 at 7:59 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.